Hello Marketo Community,
Has anybody had any luck disabling Autocomplete in newer versions of Chrome? When you use the "Disable Autocomplete" functionality in the Forms Editor, it simply changes the code to autocomplete="off" . Unfortunately, Chrome now ignores this command. From what I found, changing the code to autocomplete="new-password" will work, but I'm not sure how to change that in Marketo. Does anybody have any insight on this?
Thank you,
-Keith
Solved! Go to Solution.
MktoForms2.whenRendered(function(form){
var formEl = form.getFormElem()[0],
autocompleteDisabledEl;
while( autocompleteDisabledEl = formEl.querySelector("[autocomplete='off']") )
autocompleteDisabledEl.setAttribute("autocomplete", "new-password" );
});
But don't expect a full cross-browser-version solution to be simple, or even possible... this is still a buggy area in browsers.
MktoForms2.whenRendered(function(form){
var formEl = form.getFormElem()[0],
autocompleteDisabledEl;
while( autocompleteDisabledEl = formEl.querySelector("[autocomplete='off']") )
autocompleteDisabledEl.setAttribute("autocomplete", "new-password" );
});
But don't expect a full cross-browser-version solution to be simple, or even possible... this is still a buggy area in browsers.
Worked like a charm, Sanford. Thank you so much!
Hey Keith, are you referring to the Forms Editor in Marketo or Chrome? I cannot find any setting in Marketo to turn off the autocomplete. Can you share a picture if it is Marketo.
Thanks a lot
Axel
There's no relevant setting in the Form Editor AFAIK. Wouldn't work anyway.