ItzikEdar
ItzikEdar

Reputation: 207

ios7 issues with webview focus when using keyboard html

Sencha - I have a webapp with a registration form that works correctly on Safari. However, for some reason when adding the page to home screen (using ios webview) this issue appears:

When I click on a text field the keyboard is not zooming to the specific field that was selected. In order to start writing to that text field, I need to press again on the text field.

I am using sencha.

Upvotes: 10

Views: 17546

Answers (2)

George
George

Reputation: 125

I faced the same issue. In my case i am using jquery mobile and to solve this issue i added the attribute "autofocus" to the input field.
This seems to simulate a first tap on the field whereas the tap by the user opens the keyboard and he will be able to write to the field.
Hope this helps.

Upvotes: 3

J. Furr
J. Furr

Reputation: 396

I found the solution for iOS 7. Use the following meta tag in your HTML pages:

<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, maximum-scale=1.0, target-densityDpi=device-dpi" />

Upvotes: 28

Related Questions