• Derek Wilcox

    (@themassapothecary)


    I am trying to add a drop down menu in my main menu. I know I can put a page on main menu and then other pages under it so thats like a drop down menu but I want one I can just name and put the other pages I want in it. For example, I want an About Drop down menu and to put like my about us page, reviews page, best price guarantee page, lab reports page, etc under that. Is there a way to do what I am asking? Thank you in advance for all the help!

    • This topic was modified 5 years, 1 month ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not a Developing with WordPress topic
Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    You seem to be aware that you can add sub-menu items below any main menu item, so that it behaves similar to a form dropdown field. It’s not clear why that is inadequate and how adding one you “can just name and put the other pages I want in it” would be any different. Can you explain why the default sub-menu capability will not work for you? Perhaps it will clarify what you are trying to accomplish.

    I’ll add that you can programmatically add arbitrary HTML to the menu HTML through the “wp_nav_menu” filter. The added HTML needs to be wrapped by a <li> element with appropriate classes for your theme to display it as part of the menu. Maybe that will point you in the right direction without needing to further explain what you are trying to do.

Viewing 1 replies (of 1 total)
  • The topic ‘How to make a drop down menu inside my main menu’ is closed to new replies.