HTML/javaScript-autocomplete ="off"在谷歌浏览器中 [英] HTML/javaScript - autocomplete="off" in Google Chrome

查看:176
本文介绍了HTML/javaScript-autocomplete ="off"在谷歌浏览器中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以关闭自动填充表单到Google Chrome浏览器的功能? 我尝试过这种方式:

Is it possible to turn off autofill in forms into Google Chrome? I tried do it in that way:

autocomplete="new-password"

但是它不起作用.仅将输入的id和名称更改为短语:"password"可以解决此问题,但是我的脚本非常大,并且在很多地方都使用了此参数(id和名称),所以我无法更改此参数.

but it doesn't work. Only change id and name of input to phrase: "password" is solve this problem but my script is very large and use this params (id and name) in many places so I can't change this params.

我知道,关于此问题的线程很多,但是我检查了我在这里找到的所有内容并存入Google,没有任何帮助.

I know, there were many threads about this problem but I checked everything what I found here and into Google and nothing help me.

我可以使用javascript或CSS吗?也许有人对此问题有其他解决方案?

Can I do it using javascript or CSS? Maybe anyone has other solution for this problem?

谢谢.

推荐答案

问题是Chrome认为他们比您更了解自动完成功能在您网站中的运作方式.

The issue is that Chrome thinks they know better than you about how autocomplete should function in your site.

所有主流浏览器都在决定忽略autocomplete = off STANDARD(是的,这是一个标准).我有一个建议-允许网站禁用自动填充功能,就像用户访问位置一样,该权限由用户授予该网站.请进入铬板

All the major browser are deciding to ignore the autocomplete=off STANDARD (and yes, it is a standard). I have a proposal - make allowing a site to disable autocomplete a permission that is granted to the site by the user, just like accessing the user's location. Please go to the Chromium board

https://bugs.chromium.org/p/chromium/issues/detail?id = 914451

并对此发表评论.浏览器制造商并没有改变忽略标准的决定,但是当特定站点上的这种行为完全损害用户体验时,开发人员和用户就需要走这条路.

and comment to that effect. The browser makers aren't changing their decision to ignore the standards, but developers and users need a way off this path when this behavior on a particular site is utterly harmful to the user experience.

这篇关于HTML/javaScript-autocomplete ="off"在谷歌浏览器中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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