Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
  • #709

    I’d like to know how to modify the way sub-navigation currently works.

    Right now there is a CSS issue with it, because the third level items display as second level in the sub-navigation menu. display:none may correct that for the moment, but not what I want to do with it further.

    The way I want to display the third level items is, when I click on second level link from the sub-navigation menu, the second level page would only displays third level nav items in the sub-navigation menu, and the static “Sub-Navigation” header would replace the name of the second level navigation link that I just clicked.

    I kind of don’t like the “Sub-Navigation” header being static, it definitely needs to be corrected to change dynamically.

    The problem is, I dont know how to do this, with my limited php knowledge.

    Any help appreciated.





    Can you post the site URL?

    Best regards,



    I purchased the theme from themeforest, user is: bgbs


    I added this code <h3><?php the_title(); ?></h3> where “Sub Pages” header text was displaying and that seems to display the dynamic header correctly to a certain degree, but I still need help correcting the sub-navigation links.

    Basically my pages are setup like this

    Parent Category = Products

    Second level Category = Products ->Crown & Bridge

    Third Level Category = Products->Crown & Bridge -> Crowns

    Right now if you click on Parent Category the sidebar links display Second and Third Category Links in one nest.

    Then, if from the Sidebar menu, you click on say Second level category “Crown & Bridge” the header changes to “Crown & Bridge” as it should, but the links still display say Second and Third level categories where as it should only display the Third level links instead. Lastly, if you click on the Third Level link “Crowns” the menu all of a sudden displays only third level links, which is correct.

    Any thoughts how to correct these problems?



    Sorry, I’m really confused by what you expect it to do and what’s going on.

    Can you provide screenshots of the pages with problems and highlight the issue?




    Image Links.

    In the first image you will notice that Second and Third Level category links show in one level (not nested). Third navigation links should not be displayed unless I’m inside the second level category.

    The second image shows what happens once I click on second level category link. You will notice that second and third nav items still display on same level (not nested). What I want to do here is have the Second level links disappear from the menu and only show third level nav links. You will also notice that now the Nav Title displays “Crown & Bridge” which is the way it should be.

    The third level displays what the third level category links look like.

    Let me know




    I understand now, how have you added this menu? I’m guessing it’s custom coded but does it use the WordPress Navigation Menu function or something else?

    Can you post the code if it’s not the WP Navigation Menu?

    With a little CSS trickery, it’s possible to hide the sub-navigation if it shouldn’t be shown – if it’s custom coded you should be able to conditionally allow the menu items to show up.



    i’m using wordpress menu



    $children = wp_list_pages(“title_li=&sort_column=menu_order&child_of=”.$post->post_parent.”&echo=0″);


    $children = wp_list_pages(“title_li=&sort_column=menu_order&child_of=”.$post->ID.”&echo=0″);

    if ($children) { ?>

    <div class=”small_box widget_pages”>

    <h3>” rel=”bookmark” title=”Permanent Link: <?php the_title(); ?>”><?php the_title(); ?></h3>

      <?php echo $children; ?>




    I’d recommend switching over to the Custom Menus built into WordPress to give you absolute control.


Viewing 9 posts - 1 through 9 (of 9 total)

The topic ‘Sub Navigation Alteration’ is closed to new replies.