How to set up to prevent the browser from automatically saving form information, such as user name, password?
Now many browsers have the auto-fill function, I use the input on the autocomplete= "off", but in some browsers are still remembered the user name and password, is there a more efficient and convenient way to prevent the browser to remember the user name and password?
1. Remember the password for the browser
1). First, most browsers determine the password domain based on the type= "password" of the form field, so there is a way to "dynamically set the Password field" for this situation:
<input type= "text" name= "password" onfocus= "this.type= ' Password '" autocomplete= "Off"/>
Explanation: When this document box gets the focus, it becomes the password field, so the browser will not remember the password, of course, in order to be more perfect, you can also add the autocomplete= "off" attribute.
2). In the OnLoad event, empty the value of the password box, i.e.:
<script language= "JavaScript" > window.load = function () { document.getElementById (' Password domain ID '). value= '; }; </script>
3). The page uses the HTTPS protocol because HTTPS does not store information on the form.
4). Use Flash to do a login form, in which case the browser does not log form information.
5). Another perverted good, that is, you can change the type= "password" to type= "text", because the type is not password will not appear to remember the password function, and then set a variable such as: Var val= "" or set a hidden field < Input type= "hidden" Name= "Val", and at the end of the Onpropertychange the password to a line of dots, and assign the value to Val, and then return the value of Val back, due to the same effect as the * number. The user is not visible.
Prevent browsers from remembering usernames and passwords