• Nick

    (@njprrogersgmailcom)


    Hi,

    I’m creating a sub navigation on a page using wp_list_pages. Unfortunately, when I go to the Level 3 navigation in the sub menu, the Level 2 navigation disappears.

    To illustrate, my page looks like this from a navigation point of view:

    Primary Nav
    Level 1 | Level 1 | Level 1

    Sub Nav
    Level 2
    Level 2
    — Level 3
    — Level 3
    Level 2

    My wp_list_pages for the sub nav looks like this:

    if($post->post_parent)
      $children = wp_list_pages("title_li=&child_of=".$post->post_parent."&echo=0");
      else
      $children = wp_list_pages("title_li=&child_of=".$post->ID."&echo=0");
      if ($children) { ?>
      <ul>
      <?php echo $children; ?>
      </ul>

    Thanks in advance!

    Nick

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘3 levels of navigation’ is closed to new replies.