默认情况下,iOS 的键盘将文本表单字段中的第一个字母(包括 type=email)设置为大写。 (至少在 iOS 5 之前。)

有没有办法禁用自动大写?

最佳答案

从 iOS 5 开始,type="email" 自动禁用了自动大写,因此您只需要:

<input type="email">

对于其他输入类型,有一些属性可以执行它们所说的:
<input type="text" autocorrect="off" autocapitalize="none">

如果出于某种原因您想在版本 5 之前支持 iOS,请将其用于 type="email" :
<input type="email" autocorrect="off" autocapitalize="none">

更多信息:
  • iOS Documentation
  • Controlling which iOS keyboard is shown
  • 关于ios - 你如何在 iOS 的 HTML 表单字段中关闭自动大写?,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/5171764/

    10-14 20:11
    查看更多