I'm working on large site with top-navigation menu for top-level pages only. Is there any way to make sub navigation menus work as on image attached? I hope the problem is in myinsufficient PHP-skills, not in limitations of Wordpress. desired result in balsamic mockup

Top-level navigation menu is made with standard wp-nav-menu. This navigation bar is separate from subnavigation bars. The problem is in the first sub navigation bar (child pages of current top-level pages) and the second navigation bar (child pages of current child page)

First line should show all the sub-pages of current top-level page (if there is any), and second line should display sub-pages of current sub-page (if there is any). I'm trying to make it easy for updating and navigating the website, so, that sub navigation show location in the page hierarchy.

I tried all the wp_list_pages code examples from Codex, and tried to achieve the desired result with plugin "Custom Menu Wizard", but I couldn't make it work properly. Either only siblings are visible (no parent pages and their siblings) or the whole list of complex hierarchy (not relevant to current page). Is there any way to make this work, or should I use solutions like three-level drop downs?

  • 4
    Gladly your img shows what you want. For the sake of search: Please file an edit and add it as machine readable text to the question - someone with bad sight might enjoy user sizable text as well. And please show us what you've tried. Currently it's a job description instead of a question plus your research, tries and fails. – kaiser Feb 12 '14 at 13:22
  • 2
    So you don’t ask how it could be done, just if? Why? – fuxia Feb 12 '14 at 15:02
  • Why wp_list_pages? I would advise using wp_nav_menu instead – Tom J Nowell Feb 12 '14 at 15:12

You can manage that with a single menu, and using CSS you can style to function the way you have described very easy.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.