Am I right that the .focus() method always has two effects? It
can give the focus to an input field, but it also always gives
the focus to the browser window and moves it to the top. Are
these two effects inseparable?
My aim is to make web sites operable without a mouse, with the
keyboard only. That's usually a requirement for good user
The negative example is http://www.yqcomputer.com/
, where you cannot
easily get to the search input field without using the mouse. I
think that's a mistake from the point of view of user
interaction, because it requires changing from keyboard to
mouse, then back to keyboard, which is unnecessarily awkward and
The positive counter-example would be http://www.yqcomputer.com/
where the cursor appears in the all-important input field after
the focus to the input field after the page is loaded? That's
what I would tend to do. Any traps along that road?