如何禁用 Chrome 自动填充功能(2020 年后) [英] How to disable Chrome autofill (after 2020)

查看:28
本文介绍了如何禁用 Chrome 自动填充功能(2020 年后)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在过去的一段时间里,我偶然发现了这个问题几次,Chrome 忽略了 autocomplete=false"autocomplete=off".它现在甚至会忽略 autocomplete="whatever" 或任何你做的欺骗它的事情,如果有人提交了一个带有随机hack"的表单.之前在里面.

I've stumbled across this issue a couple of times in the last while, where Chrome ignores autocomplete="false" and autocomplete="off". It will now even ignore autocomplete="whatever" or anything you do to trick it, if someone has submitted a form with that random "hack" in it before.

在尝试解决这个问题时,我遇到了这个 StackOverflow 问题,但没有解决如果您之前提交过包含此字段的表单,则会出现问题.

In trying to solve this issue, I came across this StackOverflow question, which doesn't solve the problem if you've submitted a form containing this field before.

这不适用于密码字段.

推荐答案

我遇到了一个带有number"的字段的问题在名称中,这会触发信用卡自动完成对话框.这个解决方案帮我摆脱了它.

I had this issue with a field that has "number" in the name and this triggering the CreditCard Autocomplete Dialog. This solution helped me get rid of it.

即使这不是该选项的预期用途,我认为这不太可能在没有 JavaScript Hacks 的情况下破坏和工作.一次性代码不会触发自动完成,因此我将不应自动完成的字段视为一次性代码.

Even though this is not the intended use of the option, I think this is unlikely to break and works without JavaScript Hacks. A one time code won't trigger an autocomplete so I treat the fields that are not supposed to autocomplete as one time codes.

<input type="text" name="number" autocomplete="one-time-code" />

这对我有用.我在 Chrome 87.0.4280.141 上测试过,效果很好.

This did the trick for me. I tested it in Chrome 87.0.4280.141 and it works fine.

这篇关于如何禁用 Chrome 自动填充功能(2020 年后)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆