This is a first small patch that attempts to clean up the settings page under ?q=admin/settings. It moves the settings on ?q=admin/settings to a sub-page and replaces the main settings page with an overview of all sub-pages.

Motivation:

  • A number of people told me it took them a while to notice that there are subpages on ?q=admin/settings. They only saw the settings on the main settings page. This patch attempts to fix this usability problem by giving all setting pages equal visibility/weight. That is, it moves the settings on the main settings page to a sub-page.
  • Earl Miles is exploring better ways to present and navigate the settings. There is no good reason for Earl's proposed changes to be limited to the main settings page. This patch gets us a step closer to treating all setting pages equally, making it easier to make global changes to the settings code.

Applying this patch shows that the menu items used for the settings pages need to change -- we need to make them more meaningful, and maybe split up sub-pages in multiple sub-pages. For example: 'system' should probably be split in 'general', 'caching', etc, etc. I'd prefer to leave that for a second patch. (I think I'm going to elimate the _settings hook, and implement setting pages using the regular callback mechanism.)

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

merlinofchaos’s picture

I completely agree with this direction.

Dries’s picture

FileSize
35.58 KB

Spent most tonight working on the settings patch. Give it a try and let me know what you think.

When you apply the patch, make sure to flush your menu cache: DELETE FROM cache;.

Dries’s picture

FileSize
59.47 KB

I updated all core modules. New patch attached. Unless someone has comments, this patch is done.

Dries’s picture

FileSize
750.52 KB

Attached is a screenshot of the new ?q=admin/settings page and part of the new 'administer > settings'-menu.

killes@www.drop.org’s picture

looked at the screenshot only: I find it confusing that the menu does not seem to have the same items as the main page, ie there are additional items for the main page. Maybe we should remove the menu?

Dries’s picture

Here is a summary of what the patch does:

  1. Substitutes the general settings on ?q=admin/settings with an overview page. This gives all settings equal weight/visibility which fixes some usability reports (see above).
  2. Deprecates the _settings hook. To create a settings page, you now have to use the regular callback mechanism like any other page in Drupal. There is no need for the setting pages to be a special case (code-wise).
  3. Some setting pages have been split into two or more sub-pages. For example, the general settings (?q=admin/settings) are split in 'site information', 'page caching', 'rss feeds', etc. This makes it easier to find settings.
  4. The settings sub-menu in the main navigation menu now uses meaningful names for its menu items rather than the internal module name. For example, 'settings > drupal' is now 'settings > site registry' and 'settings > distributed authentication'. Or 'settings > profile' is now 'settings > user profiles'.
  5. I cleaned up some form code. Minor changes.
Dries’s picture

killes: they have the same items but aren't listed in the same order. I'll have to fix that.

Stefan Nagtegaal’s picture

Dries, it's not very clear to me what the advantage of this is, or should be..
I would love to see it, but unfortunatly I can not find the advantages...

Is this the final state of admin/settings? Only the links to the pages which are desplaying the seetings?

If that is the end goal, I would love to get rid of the whole admin menu.. We can help users with breadcrumbs to let them navigate through the settings...

I think...

Dries’s picture

killes: quick follow up on the order of the items. I haven't fixed this because I think it might be a /bug/ in the menu system. Think about it for a minute. It looks like the menu system doesn't store/cache the menu tree in a sorted state. If we do the sorting after the menu is retrieved from the cache and unserialized, we might be burning a lot of CPU cycles. I haven't fixed it in my code, because I want us to investigate this more. Maybe we can modify the menu system to store the menu in a sorted state. It would certainly be a performance improvement. Anyway, I still have to investigate this -- maybe I'm just doing things wrong.

stefan: this is likely to be an intermediate state. But for now, it is the final state. If you can't see the advantages, that is probably because you haven't tried the patch or because you don't understood the code changes. If you did try the patch, it would appreciate a more detailed review. Your comments don't get us anywhere, nor do I understand what you mean with "help users with breadcrumbs to let them navigate through the settings" ... please be more specific, or provide a screenshot/patch to make your point. Thanks!

killes@www.drop.org’s picture

I think I am ok with this patch. Deprecating the settings hook and using the menu system is a straigthforward improvement.

Some beautification of the page should be done in a second step.

I also never liked the many collapsible fieldsets on the page.

Dries’s picture

FileSize
75.87 KB

Updated patch.

  1. Updated CHANGELGO
  2. Removed some cruft and improved consistency
  3. Grouped all setting pages

I'm pretty much done with this patch.

beginner’s picture

The patch applies with a 21 line offset on user.module.

Generally speaking, I like the idea behind the patch. I found it always unnerving that I had to load the whole core setting page just to access the module setting pages on the lower rung.

some comments, though:

1) I have the same comment as Killes on the differing order of the items. (but Dries already replied to this).

2) I find it confusing to have the core settings mixed in together with the module settings. Before, I knew I had one menu item under admin/settings/ for each module. When enabling each module, I can look in the list (menu) and it reminds me what modules I have enabled on this particular site.

(my definition of 'core settings' are those for the required modules that cannot be turned off. In general, I am looking for only one (at most) additional setting link for each additional module enabled).

=> can we solve this by grouping the core settings entries together (in one list), and the hook_settings() on a second list, each with an appropriate title/header?
The idea is that beside the few core settings grouped on one side, I'd have the module settings grouped on the other side, with exactly one link per module (or one link per hook_setting()).
This could be easily (??) achieved in the main area of the page (print two lists under different headings).
In the menu, we could:
a- leave it as is,
b- have two sub-menus: admin > settings > core settings > list of core settings and admin > settings > module settings > list of modules with settings (forces to click through one more page, unless the menu item is set as expanded per default, which allows us to collapse the core setting sub-menu once done with the initial core settings).
c- split the menu into two parts: admin > settings (core) and admin > settings (modules).
d- leave as is, but with core settings coming first in the menu, and module settings coming last, with a separator between them.

(obviously, I am not considering here the difficulty of implementation, which is also an important issue. I'm just brainstorming about different alternatives).

3) Not crucial, but the link appear lonely in the middle of the page. Maybe, in this patch or later, a short plain text description can be added beside the link.

Hmmm.... looking at the code, I guess Dries will not like my comments: none of what I propose can be easily implemented ;)
So, my final comment is: I don't object to the patch as it is, now. I was just expressing my first impressions when watching the result.

Dries’s picture

Thanks for the review beginner. I agree that there is room for more improvements.

When patch #72079 (overall administration page) lands we can probably make the settings page look like the screenshot in http://drupal.org/node/72079#comment-112765. That is, we could turn the itemized list into a definition list, and provide a one-line description with each link.

Furtermore, the settings overview page might actually disappear. Chances are it becomes a block on the main administration page -- see the screenshot in http://drupal.org/node/72079#comment-112765. If the settings page continues to exist, some categorization might be in order.

I'd prefer to commit this patch and focus my energy on #72079 (which involves both making nice overview pages and categorizing administration pages).

beginner’s picture

oh!
In that case, assuming that module settings are still at admin/settings/module, what would happen if I access admin/settings ? 404?
Or maybe you mean that we should have admin/mymodule/settings ?

The general site configuration in the screenshot doesn't separate the core settings from the module settings as I mentioned above.

Dries’s picture

FileSize
119.17 KB

what would happen if I access admin/settings ? 404?

We don't know yet. We're about to start working on that. We'd probably need some sort of overview page. :-)

The general site configuration in the screenshot doesn't separate the core settings from the module settings as I mentioned above.

It doesn't. Note that in the newer versions of the patch there is no 'general' anymore. I attached a new screenshot.

One of the things we've been talking about (and which we'll be working on) is to present the core configuration pages as part of the installation steps (wizzard).

Dries’s picture

I've been thinking about this some more, but it is hard to come up with a definition for 'core settings'. AFAIK, there are no settings that require one's attention, except maybe for the site's e-mail address. It's hard to say what settings are 'important' or what settings are 'not important'. Do you have a proper definition?

Dries’s picture

FileSize
30.44 KB

Here is another screenshot. I converted the overview page to a definition list, and provided a description for the first items in the list. Just to give a quick idea of how it would affect the page.

I'm not sure this is an improvement; the descriptions aren't all that useful IMO. They might do more harm than good.

Your OS's system preference dialog doesn't provide descriptions either. They do icons though. Maybe that is what you're looking for? ;) Anyway with this patch, things are more like you OS, minus the icons.

killes@www.drop.org’s picture

I think all the settings which are required (as in "required form element") are quite important and should be more easily accessible. A module author should then mark some setting as required if the module won't run otherwise. So, the site email address woruld be required and should be easily accessible. Same for the files directory, but maybe not for the cache and date settings.

Dries’s picture

It only takes a couple of lines to mark links that point to pages with required settings.

Though, what settings are _really_ required? AFAIK, none of them are.

The files settings are only required if you want to upload files. I don't upload files on buytaert.net. The e-mail address is only required if you want to send e-mails (that people can reply to). I don't send e-mails on buytaert.net. Plus, many of the required settings have good defaults. At the same time, if performance matters, the page caching settings become required.

My point? It's easy to do, and we can do it afterwards. The problem is creating guidelines about what is required, and what isn't. Let's do this in a follow-up patch.

killes@www.drop.org’s picture

I am fully ok with addressing the "which setting is important" part later.

Your use of Drupal on buytaert.net is IMHO overkill, you'd be better served with wordpress or some other blogging tool. ;)

I am pretty sure that 98% of all Drupal installs have at least sent a mail once. Having a mail sender that people can reply to is a good thing even if the mail (like password reminders) isn't intended to be replied to, "root@localhost" doesn't cut it.

I think the file settings should only be displayed if a module that uses them is enabled.

beginner’s picture

Dries: your third screenshot seems to be broken. I cannot view it.

When I was speaking about 'core' settings, I didn't mean 'important' settings.
I gave my definition above.
At first, by 'core settings' I meant everything that is currently under admin/settings and that is broken up into different parts with this patch.

But my final definition of what is a 'core setting' is, as mentioned above, all the settings that are still available after having turned off all non-required modules.
For all additional module being enabled, we should have only one set of settings, accessible via a single link. One module = one link to one group of settings.

This is a useability issue. If an admin enables one more module, she should be looking for a maximum of one addition link, not two leaving her wondering if she missed a third one.

According to this definition, I think it would be best if we could have all the 'core settings' grouped together, and the module settings listed separately (but not far :) ).

merlinofchaos’s picture

I think when the admin overview page is done, this re-organization will address -- if not quite wholly -- your issues.

Dries’s picture

So unless there are important objections, I'll go ahead and commit this patch.

webchick’s picture

Please don't commit just yet -- I want to give it a try first... will post a review within the hour.

webchick’s picture

Status: Needs review » Needs work

Ok, my first thought is "yikes" ...

a) One of the first things I do when testing a "mega patch" like this one is turn on every core module. Here's what my admin/settings page looks like:

* RSS aggregator
* blog APIs
* comments
* contact form
* sites registry
* distributed authentication
* forums
* user profiles
* access logging
* throttle
* uploads
* menus
* posts
* content types
* site information
* error reporting
* page caching
* file system
* image toolkit
* RSS feeds
* date and time
* site status
* unicode
* cron status
* clean URLs
* users

To the casual observer (and even the non-casual observer), this is utter chaos. Pretend you're a new user and have never before used Drupal in your life. Now try and find where you'd configure file upload permissions. Unless you either really like reading or are handy with Ctrl+F, you're going to be staring at this screen for a very long time.

b) In #7 you said:

killes: they have the same items but aren't listed in the same order.

However, here's what my settings menu looks like (even after DELETE FROM cache):
# settings

* clean URLs
* content types
* cron status
* date and time
* distributed authentication
* error reporting
* file system
* image toolkit
* menus
* page caching
* posts
* RSS aggregator
* RSS feeds
* site information
* sites registry
* site status
* unicode
* user profiles
* users

Notice that several items are missing here: including forum and upload. So even if I ignore the utter chaos of the admin/settings page (which presumably gets fixed in some way with merlin's follow-up patch), and instead go with the menu which is ordered alphabetically, I can't. I am forced to hunt and peck through the big list looking for the settings page I need. This seems like a bug.

c) Also note fun things like RSS aggregator and RSS feeds being nowhere near one another, even though "conceptually" they're referring to the same kind of stuff.

d) Note also that for example "image toolkit" brings up nothing at all on its setting page other than the Save Configuration and Reset to Defaults buttons. That also seems like a bug.

e) A comparison to Windows Control Panel doesn't really work here, because Control Panel (and Apple's System Preferences, etc.) uses icons to easily identify where groups of settings are. If I'm looking for printer settings, I look for the picture of the printer. I don't need to read every single description (or any description, really) looking for which one says "Printers and Faxes." I can also easily go back to that icon because the items are listed in alphabetical order. It's going to be after "Power Options" and before "QuickTime" (ewww, how did QuickTime get on this machine? ;)).

This has been my biggest complaint with attempts at re-working the admin section -- the lack of visual cues to allow viewers to easy "drill-down" to the information they require, simply at a glance. I can accept, however, that UI improvements of icons and such should be a separate patch. I just want to strongly note that what is here now is going to cause more confusion than a hierarchical, alphabetical listing we have now, unless something like this is done.

---

What I would suggest in the interim, which would get around massive UI changes but still make some sense out of the current list on admin/settings, would be some way of grouping settings pages by module. For example:

What I would suggest instead is grouping these by modules, in alphabetical order.. for example:

<fieldset>
System (always at the top)
<ul>
  <li>clean URLs (list of settings pages ordered alphabetically)</li>
  <li>date and time</li>
...
</ul>
</fieldset>

<fieldset>
Aggregator (rest of core/contrib modules ordered alphabetically)
<ul>
  <li><a href="http://localhost/head/?q=admin/settings/aggregator">RSS aggregator</a></li>
</ul>
</fieldset>

<fieldset>
Blog
...
</fieldset>

Make sense?

webchick’s picture

Btw, marked "code needs work" because:
- The fact that different settings show in the menu vs. on admin/settings seems like a bug.
- The fact that there are totally empty settings pages seems like a bug.
- IMHO, just in case a follow-up patch does not make it in, we really need admin/settings to be at least somewhat usable, even if it only ends up being this way in HEAD for 2 weeks or something. The way it is now is just too confusing.

If you disagree, of course, just set it back. :)

merlinofchaos’s picture

webchick: IMO the organization is a matter for my patch that Dries mentioned earlier, and I am actually very interested in getting this in as a stepping stone toward the re-org. Once we have the re-org, settings will be in their more logical placements.

Dries’s picture

FileSize
75.92 KB

Changes: made sure that the menu is in sync with the overview page. New patch attached.

webchick: thanks for the review. Note that this isn't any more confusing that what we have now.
This patch simply draws more attention on Drupal's crappy settings page -- it doesn't make it worse. If you enable all modules in Drupal 4.7 you'll also have a long list of settings-related menu items. Worse, many of those menu items will be incomprehensible. For example, the drupal.module's settings menu item is called 'drupal' and let's you configure 'distrubuted authentication'. At least with this patch, it reads 'distributed authentication'.

As mentioned several times, the categorization of the the settings pages will be taken care of by the next patch (which Earl is currently working on).

Dries’s picture

Status: Needs work » Needs review
webchick’s picture

Status: Needs review » Needs work

As mentioned several times, the categorization of the the settings pages will be taken care of by the next patch (which Earl is currently working on).

Yeah, I realize that. My concern was that this page is totally un-usable until that patch lands. But now that the menu items are all there, and sorted in alphabetical order, this should provide a suitable workaround for the short-term.

"image toolkit" is still blank, and hunk 1 of 6 on user.module fails... it's the part changing the welcome message.

webchick’s picture

Status: Needs work » Needs review

Hi, I am a moron. :P I should update HEAD before applying patches. ;)

Not sure what you want to do about image toolkit, but probably not enough of a problem to mark this "code needs work"

merlinofchaos’s picture

image toolkit probably just needs an explanation that you have no additional image toolkits installed and that you can only use the default. That'll solve the blankness and the only difficulty, really, is writing the explanation. IMO.

Dries’s picture

FileSize
76.65 KB

Changes:

  • Fixed bug with the settings page for file uploads.
  • Added a status message when no image toolkits are found; removed the buttons when that is the case.
  • Sorted the settings on the overview page.
webchick’s picture

Status: Needs review » Reviewed & tested by the community

Ohhh, excellent! Thanks so much, Dries!

Tested and works as stated. As an added bonus, it took the buttons off "cron status" which is just a message to let me know it hasn't run.

RTBC. :)

rstamm’s picture

Status: Reviewed & tested by the community » Needs work

After fresh install, cannot run clean url test.

rstamm’s picture

Status: Needs work » Needs review
FileSize
1.91 KB

patch fixes clean url test

Dries’s picture

Status: Needs review » Fixed

Committed. Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)