Friday, August 18, 2017

website design - Drawbacks of auto "focusing" on a web page's text field (JavaScript)



Do you guys know any drawback of focusing on a text field on a web page ? It's pretty useful when you know users will use this text field more than others (like on the google homepage), but it's a bit "offensive", so I wondered if there's something bad that could happen (on mobile devices for example)



Answer



Normally the Backspace key takes you back a page as it is a keyboard shortcut for the Back button. When an input field is focused, the backspace only works within the input field. For many keyboard users (as in prefer the keyboard and avoid switching between keyboard and mouse) it therefore is a definite drawback when a site auto focuses an input field arbitrarily.


That said, I do not like pages not to auto focus on the first field when the whole purpose of the page is to fill out a form and submit it.


So I guess basically the rule for me would be: auto focus for data-entry forms; do not auto focus when input is a secondary (or even lower) item on a page.


No comments:

Post a Comment

technique - How credible is wikipedia?

I understand that this question relates more to wikipedia than it does writing but... If I was going to use wikipedia for a source for a res...