WordPress.org

Ready to get started?Download WordPress

Forums

Page Sidebar related links to PDF, videos, other content (4 posts)

  1. beyoyo2
    Member
    Posted 5 years ago #

    I have been looking for a plugin that can handle links to related materials for each PAGE (not post). I realize I will probably need to make a template for each page... but I don't want to hard code the links for the sidebars. The client will need to edit them and add to them from time to time.
    Looked at Related External Links(posts only) and Manual Related Links, but I don't think it will be possible with either.)
    Any suggestions?
    Thanks

  2. esmi
    Forum Moderator
    Posted 5 years ago #

    Why not set up special Link categories and then display them as needed in the sidebars using the is_page() conditional?

    <?php if(is_page('About')) wp_list_bookmarks('title_li=&category_name=About Links');?>

  3. beyoyo2
    Member
    Posted 5 years ago #

    This goes in the sidebar.php correct?

  4. beyoyo2
    Member
    Posted 5 years ago #

    I added this to my sidebar.php page, but it shows all of the bookmarks list no mattter what page you are on. Need some guidance.

    <li class="widget"><h2>Linkss</h2>
    <ul>
    <?php if (is_page('about')) { ?>
    wp_list_bookmarks('title_li=&category_name=about_links');
    
    <?php } elseif (is_page('industries')) { ?>
    wp_list_bookmarks('title_li=&category_name=industries_links');
    
    <?php } elseif (is_page('services')) { ?>
    wp_list_bookmarks('title_li=&category_name=services_links');
    
    <?php } ?>
    
    </ul>
    </li>

Topic Closed

This topic has been closed to new replies.

About this Topic