开发者

How can I disable the spell checker on text inputs on the iPhone

Sometimes the spell checker is unnecessary, captchas, usernames, emails, etc. Is there a way disab开发者_如何学JAVAle it on some text inputs/text areas?


As noted by my buddy Jonathan Stark, you should be able to use attributes like autocorrect and autocomplete to achieve the effect you're looking for:

<input type="text" placeholder="My Field" name="myfield"
    autocapitalize="none" autocorrect="off" autocomplete="off" />

Just tested in OS4 and it's working.

UPDATE: As of iOS5 on and off values in autocapitalize have been deprecated. Use none to completely disable automatic capitalization.


Actually there is literally a spell check attribute in HTML5:

<textarea spellcheck="false">

Re: http://blog.whatwg.org/the-road-to-html-5-spellchecking

Browser support is, of course, limited.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜