ThemeShaper Forums » Power Blog


Make function in functions.php display only if is front_page

(3 posts)
  1. I need to only display the 3 leader asides (and a custom function) on the front_page.

    I used Widget Logic, but it only removes the widgets, not the leader div and its borders.

    So I tried to place if is_front_page() on several spots in my functions.php, but somehow I have not find the right location. Someone has a map for me? ;)

    This is the custom function (you know the asides code I guess)

    // Adds the Partner div above the footer
    function childtheme_partnerlinks() { ?>
         <div id="partner">
    	      <div id="partnerinfo">
    <?php }
    Posted 11 years ago #
  2. This CSS fixes the leader div to be not displayed (except on the front page)

    body.singular #leader,
    body.category #leader, #leader {
    body.home #leader {

    but I would prefer some if_front_page magic for the functions.php to get rid of that extra plugin.

    Posted 11 years ago #
  3. curobs

    Warning. This fix causes the leader to disappear on home page in IE7. Better to go with Chris' solution at

    Posted 11 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.