Hi
I want to change the input's type, from "text" to "password" using the
focus event. I use the following jquey code
<script type="text/javascript" language="javascript">
$(document).ready(function(){
$("#passwd").focus( function() {
$(this).attr("value","");
$(this).attr("type","password");
} );
});
</script>
Il woks nice in FireFox but not in IE ! I tried diffent a way like :
$("[EMAIL PROTECTED]'password']").focus( function() {
$(this).attr("value","");
$(this).attr("type","password");
} );
or :
document.getElementsByTagName("password").setAttribute("type", "password");
Here is my html code:
<form method="post" id="loginID">
<input name="password" type="text" id="passwd" value="Your
password" />
......
</form>
thanks for your help.
Djam