第一次在 input 输入后,下次就会自动显示输入历史记录,去掉这种默认效果的解决方案

<input name="username"  type="text"  autocomplete="off">

 

input 的属性 autocomplete 默认为 on,其含义代表让浏览器自动记录之前输入的值

如果想要关闭记录可以在 input中 加入 autocomplete="off"

 

相关文章:

  • 2021-06-25
  • 2022-12-23
  • 2022-12-23
  • 2021-07-06
  • 2021-12-16
  • 2022-01-14
猜你喜欢
  • 2022-01-15
  • 2022-12-23
  • 2022-12-23
  • 2021-08-27
  • 2022-12-23
  • 2022-02-09
  • 2021-11-30
相关资源
相似解决方案