Add Descendants As Submenu Items

When I created the navigation menu at the top of my site using the menu feature in WordPress (Appearance → Menus), I didn’t want to have to maintain anything but the top-level menu items. When I released a new plugin and created a page for it, I didn’t want to have to go into my menu UI and add it there too. So instead I wrote this plugin.

Add Descendants As Submenu Items adds a checkbox to each menu item that is of a hierarchical post type (i.e. pages) or taxonomy (i.e. categories). Checking this box will automatically display all descendants as submenu items on the front end of your site. You can see it in action at the top of my site — I only configured the top level menu items and everything that shows up when you hover over them has been added by my plugin rather than manually by me.

Great plugin, Alex. I wasn’t sure at first whether each parent item could have submenus enabled separately, but a quick play with the plugin confirmed this feature. One less thing for the less technically-minded person who updates the site to have to worry about!

Hi Alex, thank you very much, you’ve saved me a ton of work. I’ve rated the plugin 5 stars at wordpress.org where there is a message ‘This plugin hasn’t been updated in over 2 years.’ etc. I have it working on the current WordPress 3.9.2 using Uber menu 3. so it is working. Perhaps you can change the date of the plugin or something to remove the message.
I have spent many hours searching for a way to automatically add child or sub categories to a top menu item in wordpress. I believe this is the only plugin that will do that.
thanks again
Rob

Yeah, I need to go through all my plugins and bump their “tested up to” version numbers. I write my plugins well the first time around so I rarely need to update them — they just continue to work fine with new versions of WordPress. 🙂

Strange ya I just tried and it doesnt seem to work with my woocommerce sub menus do you think you could login mayeb and see Im in no way a WordPress Expert yet lol Im more uh CS-Cart guy but moved to woo mainly due to it having great plugin support liek YOUR! ha

I have installed your plugin, however when I click Automatically add all descendants as submenu items in Appearance-Menus , I do not get all my descendant children subcategory items shown when I hover over the main menu. Do you know why?

Exactly th same error for me. I installed the plugin on a new wordpress installation with the twentysewenteen template.
The plugin works very well everywhere except when I open “appearance > customize”.
Do you have found a solution?

Comment navigation

About

Hi and welcome to my blog! My name's Alex Mills, although on the Internet I'm more commonly known as Viper007Bond (or just Viper). I'm a Portland, Oregon web developer who works for an awesome company called Automattic (you've perhaps heard of our WordPress.com blogging website). I contribute to the open-source blogging software WordPress and have written quite a few WordPress plugins. I'm also a big car nut who is really into Top Gear and run the show's biggest fan forums. You can read more about me on my about page.

Email Subscription

Enter your email address to subscribe to this blog and receive notifications of new posts by email.