Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I prevent keyboard autocompletion in MobileSafari/UIWebView?

I'm implementing my own autocompletion on an <input> field inside a UIWebView, and the built-in keyboard autocompletion interferes with the user experience. Is there a way to use HTML or Javascript to signal to iOS that it shouldn't try to autocomplete?

like image 448
Luke Dennis Avatar asked Jun 23 '11 22:06

Luke Dennis


1 Answers

In my comments I mentioned using the html attribute autocomplete but I tested it, and it doesn't address your issue. However, there is an attribute specific to Mobile Safari which may help. You could try turning off autocorrect like so:

<input type="text" id="your-field" autocorrect="off" />
like image 133
Ben Avatar answered Sep 18 '22 23:09

Ben