2

Currently, it is up to any plugin's author as to where to put a link to the plugin's option page. I have seen at least the following "solutions":

  • Plugin list
  • Dashboard menu
  • Plugins menu
  • Appearance menu
  • Tools menu
  • Settings menu
  • Tools menu
  • Top level

In my opinion, this is very bad style (globally, not necessarily individually). In addition to the mass of links in many different locations, Wordpress does not sort them or anything.

As it is now, plugin developers can put anything anywhere in the menues and we probably want it that way; but there really should be a unified way of registering an options page such that is recognised and placed as such. Please see here, too. The old ways could remain valid, but I'd suggest recommending to use the standardised (and easy) way.

I have lately thought about writing a plugin that provides such an frontend, that is offers a function for other plugin authors that registers an options page and cares for placing links to it in the appropriate places. The notion of appropriateness could be hardcoded in a first version and be left to the user in subsequent iterations. I can even image a screen were users can put pages registered by plugins (not necessarily only option pages) were it suits them; if the user thinks this plugin's options should be there, so be it.

What do you think? In particular:

  • As a plugin author, would you delegate to such a plugin?
  • Do you think I should build it?
  • Should I rather implement the feature directly into Wordpress, hoping that the main hackers approve and incorporate it?
2
  • I can understand your motivation, but I do not think that the plattform here is working well to find a solution for this. I would first ask a question like "What is the best place for a plugins Settings?" and then would wait for answers and comments about those first.
    – hakre
    Nov 16, 2010 at 19:21
  • Funny, I had a title for this question that was similar like what you propose but changed it. I feel this question subsumes your point. But since my ultimate target would be to provide a solution where every user can define his own best place for settings, I thought the question after such was obsolete (and also not answerable in a general way).
    – Raphael
    Nov 16, 2010 at 21:03

2 Answers 2

2

There will never be such thing as a restriction of where a plugin can place a link that will display a certain page the plugin is registering.

It's just in your scenario that a plugin is registering a settings page and the link normally is named settings as well.

As there is no convention or suggestion what plugin authors can/should do, I see it even more probelmatic to restrict this. I doubt that a restriction would be technically effective and on the social side, it will only create problems for those who want/need to circumvent some more restricted approach.

This has various reasons and you are totally right, this can be a problem because it's not easy to locate all the plugins settings.

For the plugins I code that actually have a settings page, I prefer them to add in the plugin listing - at least as well. I know that some users look there if they don't locate stuff within the menu.

So it would be nice if core provides an additional routine plugin authors could call to register their settings page. For plugins that don't do that, the plugin listing could display a greyed out - no settings - or else remark.

Because I know that not all plugin authors do announce their settings page at least in the plugins listing, I've create a quicksearch plugin for the admin that let's you browse the menu quickly: Admin Quicksearch (Wordpress Plugin) - It let's you search the plugin listing quickly as well.

3
  • Thats a nice plugin, thanks. But to the point: I think it would be perfectly fine to just offer the possibility to have pages registered and handled easily without removing the current freedom (cannot, anyway, for legacy...). Because, honestly, finding out how to place pages can be a pain in itself. As a new dev, go find a comprehensive hook/filter list, good luck. I learned on a third-party site how to add that link in the plugins list, and hell is this dirty. I propose that some unified thing should be implemented. I'll edit above for clarity.
    – Raphael
    Nov 16, 2010 at 20:30
  • @Raphael - true. I normally look into the code if I find something that looks interesting to me. For example the settings link in breadcrumb NavXT got inspired by some other plugin from the top of my head. Today it's one of the plugins that even has options in- and export. something worth for multiple plugins. Probably some kind of plugin infrastructure is missing in core plus some stub plugins that show how things can be done. oh right, there is "hello dolly".
    – hakre
    Nov 16, 2010 at 21:27
  • Your point being "Yea, definitely, go ahead" or "You know, there is so much to be done, just wait for a major plugin system rework" or ... ? Import/Export is definitely something that should be put into the core, as well as proper (un)install conventions/demands. All that registrations stuff should really only be done once, not on every page load. That would also enable users to finetune e.g. execution order of hooked stuff.
    – Raphael
    Nov 16, 2010 at 22:35
2

For the vast majority of plugins, placing their settings page under settings is the correct location (and has been since WordPress 1.5). The only time this could vary is if the plugin creates a top level menu (on the same level as the "Settings", "Tools", etc menus are at). IMHO, settings is for just that, settings, and should be the fist place to look for the settings page.

There are cases where some older plugins (e.g. Spam Karma 2) add a page under the "Tools" menu, when it should not. IIRC, at one point of time, there was talk about removing the settings section. Instead of removing it, it was changed to what we have today. But in general I have not seen settings pages in places other than under "Settings". So to me it seems to be a non issue.

There is a settings API. It does not define where the settings should be located. However, an arguably evil thing it allows us to do is place more settings on the standard settings pages (e.g. add something extra under Settings > General). I really do not agree with placing extra settings on the predefined, WordPress core settings pages as it can cause quite a bit of confusion.

I really don't think users should be allowed to pick and choose where plugin settings pages are. Support would be an absolute nightmare (e.g. helping the user find the settings menu if they've changed it from where you had originally set it to be). Instead the plugin developer should put thought into where the page is located, and listen to their users if they are told it is in a poor location.

3
  • Your first paragraph is kind of offtopic, isn't it? To the second one: I can see why some people would like to find settings for plugins that change appearence under Appearance and so on (not me). But as long as there is no clear convention, devs will just put links wherever they think it makes sense when it is really a user's choice. I hate in particular that Wordpress' own options are buried in plugin settings links.
    – Raphael
    Nov 16, 2010 at 22:37
  • @Raphael: Yeah I got sidetracked, anyways, I've modified my response. And, to respond to your comment, I think it is best if plugin settings stay under "Settings" or their own main level tab and themes stay under "Appearance". Or, even better, if plugins and their settings kept under "Plugins", and themes and their settings kept under "Appearance".
    – mtekk
    Nov 16, 2010 at 23:06
  • To your updated post: I have seen all those places I list above myself. If you insist, I can provide screenshots and/or plugin names. So I think we have an issue if only one of ignorance and poor documentation in the Codex. I can agree with the heuristics you provide and also see the point why you would not want users to change places. I would counter that a user who consciously moves his links around should ab aware of that when encountering problems (but still, DAU, sure). Please keep in mind that not all users might like the same heuristic so asking "them" is not a final solution.
    – Raphael
    Nov 17, 2010 at 15:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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