3 ms·
> Another limitation is that you cannot automatically put the focus on an input field, unless it originated as a response to a user action. This is actually an
by lukifer 16y ago
> Another limitation is that you cannot automatically put the focus on an input field, unless it originated as a response to a user action.
This is actually an intentional limitation of all mobile versions of WebKit, and it's driving me nuts too. See: http://discussion.forum.nokia.com/forum/showthread.php?127724-javascript-set-focus-to-input-text-box http://discussion.forum.nokia.com/forum/showthread.php?12772...
The official explanation I've seen is that it would be jarring to the user for the page to automatically zoom and/or scroll by popping up a keyboard when the user isn't expecting it. This might make some sense for websites, but unfortunately has a side effect of crippling web apps. :(