WordPress.org

Support

Support » Themes and Templates » 2 Home buttons on Home page

2 Home buttons on Home page

  • sisterlycharms
    Member

    @sisterlycharms

    Help! This is my first blog and I have 2 home buttons on my front home page. I know that one home button is hard linked into my theme but I can’t figure out which piece of the code I need to get rid of to make 1 of the home buttons disappear. This is the code that is in my header.php which is where I think the code would be.

    <div id=”navbox”>

    <div id=”nav”>
    <ul class=”nav”>
    <li class=”<?php if ( is_home() ) { ?>current_page_item<?php } else { ?>page_item<?php } ?>”>“><?php _e(‘home’); ?>
    <?php wp_list_pages(‘title_li=’); ?>

    </div> <!– end nav –>

    Please help!!

Viewing 2 replies - 1 through 2 (of 2 total)
  • I found the fix! The trick (if you want to call it that) is to comment out the home page link. I had the same problem I thought it would be way harder. I hope it works on your code too, as mine is a tad bit different.

    <div id=”nav”>
    <ul class=”nav”>
    <li class=”first”>
    <!–
    “>Home–>
    <?php wp_list_pages(‘title_li=’); ?>

    </div>

    Sorry about that, needed to be encoded

    <div id="nav">
    <ul class="nav">
    <li class="first">
    <!--
    <a href="<?php bloginfo('url'); ?>">Home</a>
    -->
    </li>
    <?php wp_list_pages('title_li='); ?>
    </ul>
    </div>

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘2 Home buttons on Home page’ is closed to new replies.