Reputation: 2377
I've always searching how to disable autocomplete but I haven't found exact answers.
It is usually a problem of chrome browsers that setting autocomplete="off" into the html isn't working.
How do I disable autocomplete using javascript or JQuery?
Upvotes: 1
Views: 3792
Reputation: 21
You can try to use this workaround.
<input type="text" name="username" value=" " onclick="if(this.value == ' ') this.value=''" >
Click here for more info about this.
Upvotes: 0
Reputation: 1256
<script language="javascript" type="text/javascript">
$(document).ready(function () {
try {
$("input[type='text']").each(function(){
$(this).attr("autocomplete","off");
});
}
catch (e)
{ }
});
</script>
Upvotes: 2