I have this:
<input type="text" value="Enter Password" class="password" />
... onclick/onfocus, I'd like to change the input type to 'password' and value removed, like so:
<input type="password" value="" class="password" />
This doesn't seem to work:
$('input.password').click(function () {
$(this).attr('type', 'password');
});
(See this question for why I want to do this)