Reputation: 55
I am trying to cancel chrome autofilling on my inputs using autocomplete="off"
. I have a case of a <p:selectOneMenu>
which have the attribute editable=true
. Then, when I focus on the field, chrome autocomplete propose some past texts. How can I cancel this autofilling knowing that the attribute autocomplete
is not available for <p:selectOneMenu>
?
I have already tried to manage it through javascript, but the onfocus
attribute concern dropdown click and not input area focus.
Upvotes: 3
Views: 119
Reputation: 12039
Unfortunately this is not PrimeFaces related. It is that Chrome AutoFill has been a mess over the years.
Here is the thread you want and look at how many times its been updated or answers changed just in the last 3 years.
Basically Google has gone back and forth about allowing the developer to control what gets autofilled or not and for a while they completely ignore autocomplete="off"
saying developers shouldn't decide what a user wants. Then they added some new auto-complete flags. Its a 100% mess in my opinion.
Upvotes: 3