Support » Fixing WordPress » Child pages not appearing properly in main navigation

  • For some reason, the child pages attached to my 4 main navigation items are not appearing under their proper parents. Only 3 are showing, and it’s the same 3 children under each parent.

    The sidebar hierarchy of these pages show up just fine — all are properly labeled in the backend — but it’s the main navigation where they break.

    I can see in the backend that all parents are labeled as such, and all children are labeled correctly, so I can’t see any problem at all until I look at the site itself.

    Any suggestions would be greatly appreciated.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Michael


    Forum Moderator

    what is the code used for the second level page navigation?

    you might find it in header.php, depending on your theme.

    Thanks for the reply.

    I wish I knew more about the coding aspect of this. It was my developer that built the site.

    I found this in my header.php, does it make sense?

    <li class=”blog<?php echo $blog_link_class; ?>”>What’s New
    <?php wp_list_pages(“title_li=&sort_column=menu_order&sort_order=ASC&depth=1&exclude=292”); ?>
    <li class=”model_login”>Model Login



    Forum Moderator

    the code you posted is the one for the top page navigation (the ‘fancy’ tabs)

    the code for the sub-navigation might be in page.php of your theme:

    something after: <div id="sub_navigation">

    also probably containing some code with wp_list_pages()

    ok, this is what I’ve found, but doesn’t this make sense that it *would* look like this?

    } else {
    $sub_pages = wp_list_pages(“child_of=$post->ID&title_li=&echo=0&sort_column=menu_order&depth=1”);

    if ($sub_pages) {
    <div id=”sub_navigation”>

      <?php echo $sub_pages; ?>

    <br class=”clear” />
    <?php } ?>



    Forum Moderator

    this is close; it would help to see more code before these lines.

    can you paste the whole code of this file into a and post the link to it here?

    someone might have a look at it and might be able to make some suggestions.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Child pages not appearing properly in main navigation’ is closed to new replies.