Yesterday I ranted about Why You Should Never Use Colored Icons Inside the WP Admin Panel which stirred up quite a debate in the WordPress community. About 90% of the folks that I had a conversation with agreed with me, but there were strong arguments against it by some folks. In hindsight, I should have created a poll after the post to attract better & clearer feedback.
This is one other debate which we need to talk about. When building a plugin or a theme, a WordPress developer more often than not needs to provide its users with a way to configure the product at hand. Since this configuration is meant mostly for the administrators, you get to see either a new menu or a sub-menu created for it.
Responsible WP Development#
If you are like me — big fan of consistency and following coding standards is important to you then, chances are you are into what I call responsible WordPress development. As a responsible WP developer, you try and always think about the users first. How will your users interact with your product?
Do you want to be intrusive when it comes to their sites’ admin panels or do you want to weigh more on better user experience? It gets more interesting when you start talking about creating a new menu vs a sub-menu for your product. And that’s where we need to have a discussion today.
So, you have built an excellent product. Now you most definitely see it as an important thing for your users, and more so you would want to create a separate menu for it. Believe me, when I created my first few plugins, it made little to no sense to me — at that time — to why not to create a separate menu.
I wanted my plugins to be important; I wanted them to emerge as a brand and what not. But as I grew more fond of development, I realized how important of a responsibility it is for a developer to consider what’s best for the users of his plugin.
Anywho, this is strictly my opinion about this thing. I think a WordPress product should create a new menu only when:
- Your product is a big product, like a theme with lots of options, or a plugin with which users would need to interact most of the time.
- If user’s interaction with your product’s settings page happens on at least two times out of ten whenever they browse the admin panel.
Do NOT create a separate menu just to put a custom icon to help yourself brand the concept. That’s not justifiable enough.
This is a hard one. I agree. Most of the times what we build is quite important — it doesn’t hurt to think that way does it? — But at the same time, the utility of your WordPress product has a lot to do with where you put it. By no means, putting your product’s settings page inside the Settings or Tools menu says that it will be ignored or something like it’s less important.
Here’s my take on why and when you should think about creating a sub-menu for your WP product
- Small product i.e. a small plugin or a theme with very few settings on a configuration page should get a sub-menu.
- Addon for another plugin? Most definitely goes into a submenu probably inside the parent plugin’s menu.
- Does your product supports the
Set and Forget concept
? If users just need to configure your product once, it would make no sense at all to create a new menu. Sub-menu it is.
- Rate your product’s functionality from 1 to 10, where ten means most important. Now take an average for each of your product’s features’ rating and if the mean is below seven, you should seriously think about creating a sub-menu instead of a new menu. Let me help you there with defining how I do it. I think
Posts
in WordPress are an absolute 10 (i.e. most important part of WP admin panel), Media
is clearly 9 and Pages
are 8.
The Second Pomodoro!#
Clock’s ticking, it’s time to conclude this post. If your product adds a whole new functionality like custom posts types and what not, the average usefulness of its functionality will be greater than 7 (out of 10). Which means you get to create a new menu. On the other hand, if your plugin cleans up the database, or maybe has to do with including social icons to your posts, doesn’t it sound like functionality with secondary importance? It does! That’s why rating it about 5 (out of 10) would not make a lot of sense. In most cases! So, you should think about settling with a submenu there.
Ashley
If your product adds a whole new functionality like custom posts types and what not, the average usefulness of its functionality will be greater than 7 (out of 10). Which means you get to create a new menu.”
Although you could argue that by adding a CPT you’ve probably already added one new menu (for that CPT) and you shouldn’t create another top level menu just for settings. Then you’d have two! In fact, what better place to put your settings than as a submenu for the CPT? An example of this being Easy Digital Downloads.
Ahmad Awais
I agree! By adding a CPT, we do NOT by default add it in the menu. There is an option about it being added to the menu or not. That’s why you see I have been working on this listings plugin, which is quite huge, a number of CPTs in it. Here’s one Single menu that it adds. (Which resides at the top because anyone using it will have a listings website which makes the functionality more important than Posts, Media, Pages and everything). It’s a work in progress. Take a look!
David
Actually, if it’s a small plugin, if it make sense, it’s probably best to simply create section in wp default settings. Here’s how?
Ahmad Awais
Hey, David!
I’ve been to your blog and I like everything you are writing there. BTW you are actually agreeing with what I said. Thanks for dropping by!