如何禁用iPhone上文本输入的拼写检查程序

[英]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 disable it on some text inputs/text areas?

有时拼写检查是不必要的,验证码,用户名,电子邮件等。有没有办法在某些文本输入/文本区域禁用它?

2 个解决方案

#1


72  

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:

正如我的好友Jonathan Stark所说,您应该能够使用自动更正和自动完成等属性来实现您正在寻找的效果:

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

Just tested in OS4 and it's working.

刚刚在OS4中测试过,它正在运行。

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

更新:从iOS5开始,自动资本化的开启和关闭值已被弃用。使用none可完全禁用自动大小写。

#2


49  

Actually there is literally a spell check attribute in HTML5:

实际上HTML5中实际上有一个拼写检查属性:

<textarea spellcheck="false">

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

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

Browser support is, of course, limited.

浏览器支持当然是有限的。

智能推荐

注意!

本站翻译的文章,版权归属于本站,未经许可禁止转摘,转摘请注明本文地址:http://www.itdaan.com/blog/2010/08/05/3a6b2120de5db6be24b2e70e10b71ad9.html



 
© 2014-2019 ITdaan.com 粤ICP备14056181号  

赞助商广告