Skip to content Skip to sidebar Skip to footer

Autocomplete "off" Is Completely Ignored

Okay, so I know how this autocomplete='off' tag is supposed to work on all inputs except a password field and I have searched for an answer to my specific problem but it looks like

Solution 1:

The solution is actually very simple:

autocomplete="__away"

What we have done is tell any browser to completely ignore the field since __away is an air value - does not exist.

Solution 2:

Chrome unfortunately decided to ignore autocomplete="off", making it difficult on developers in hopes of maybe making some thing easier for typical users.

...we started ignoring autocomplete=off for Chrome Autofill data

Source: https://bugs.chromium.org/p/chromium/issues/detail?id=468153 (2015)

Is there a solution?

Not really... That comment continues:

In cases where you really want to disable autofill, our suggestion at this point is to utilize the autocomplete attribute to give valid, semantic meaning to your fields. If we encounter an autocomplete attribute that we don't recognize, we won't try and fill it.

But that doesn't seem to work anymore (as of Chrome 53). From the discussion here - Chrome Browser Ignoring AutoComplete=Off - as well as my own testing, there seems to no longer be a way to turn off autofill without using some kind of hack.

Solution 3:

Try setting autocomplete="new-password" in the password element. This works for chrome only

Solution 4:

Try this:

$(document).ready(function(){
    $( document ).on( 'focus', ':input', function(){
        $( this ).attr( 'autocomplete', 'off' );
    });
});

Or this:

$(document).ready(function(){ 
    $("input").attr("autocomplete", "off");
}); 

On the other hand, you might have a look at this Chrome Browser Ignoring AutoComplete=Off. Hope this helps..

Solution 5:

Many modern browsers do not support autocomplete="off".

This is the behavior in Firefox (since version 38), Google Chrome (since 34), and Internet Explorer (since version 11).

Post a Comment for "Autocomplete "off" Is Completely Ignored"