禁用 Chrome 自动填充信用卡 [英] Disable Chrome Autofill creditcard
问题描述
我的表单中有两个字段被 Chrome 错误地识别为信用卡号(一个是电话号码,一个是传真号码).还有两个名字字段,Chrome 认为它们是信用卡名称字段,并希望自动填充.我可以在这些元素上使用某些属性来告诉 Chrome 它们实际上与信用卡无关吗?
I have two fields in my form which Chrome falsely identified as credit card numbers (one is for a phone number and one is for a fax number). There are also two fields for firstnames which Chrome thinks are fields for credit card names and want to autofill. Is there some attribute I can use on these elements to tell Chrome that they are in fact not related to a credit card?
我尝试在输入上设置 autocomplete="false".这删除了地址/联系信息的自动填充选项,但信用卡选项仍然存在.
I've tried setting autocomplete="false" on the inputs. This removed the autofill options for address/contact information, but the credit card option was still there.
推荐答案
我终于找到了解决方法!将自动完成属性设置为cc-csc".该值是信用卡的CSC,他们不允许存储!(暂时……)
I finally found a workaround! Set the autocomplete attribute as "cc-csc". That value is the CSC of a credit card and they are no allowed to store it! (for now...)
autocomplete="cc-csc"
这篇关于禁用 Chrome 自动填充信用卡的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!