Monkey Do

Auto Focusing on Search Fields (don’t do it)

I’ve been a Dreamhost customer for a long time; I think it’s by far one of the best hosts in its price range. Service, support, and especially their control panel have kept me a happy user.

That having been said, there’s always something, right?

Dreamhost’s control panel does a great job of making it easy to find just about any feature they offer, and often makes tasks that, in other control panels, can otherwise be a daunting puzzle (like changing a domain’s DNS records) pleasant ones.

Unfortunately every time you load a new page, it automatically places the cursor in the search field.

Why is this a problem?

Like a lot of people, I do a lot of page navigation with my keyboard. The space bar pages you down, the down arrow moves you down in smaller increments. Shift-space pages you up. Command-up brings you to the top of the page, command-down to the bottom. Backspace/delete takes you back to the previous page.

None of these work if the cursor is already engaged — if it’s already focused on an HTML element that allows for typing, like, say, a search field.

The result being that when using Dreamhost’s control panel my behavior looks something like this:

  1. Click to open new page.
  2. Hit space bar to scroll through my unfortunately-long list of domains.
  3. Realize the search field is engaged and that I’m typing spaces into it.
  4. Be irked.
  5. Hit tab (or click on any non-link part of the page) to dis-engage the search field.
  6. Go about my business.

On some web pages (like the home page) it’s perfectly fair to make the assumption that the first thing people will want to do is type. But not on most.