By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,712 Members | 2,111 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,712 IT Pros & Developers. It's quick & easy.

Visible/Hidden value toggle on html text field

P: 1
I need to implement the following using javascript:

On a html form, after a user is finished typing in a field, and tabs out ( or uses mouse to move to next field ), the text that was typed needs to be masked like a password. However, if the user moves back in the field, then it needs to be made visible as clear text again, and the user can edit it again.

Pls help. Thx.
Sep 11 '06 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 5K+
P: 8,916
You can use the onblur and onfocus event handlers to perform this operation.

The onblur handler is called when the control loose focus and onfocus when it regains focus.
Sep 11 '06 #2

Post your reply

Sign in to post your reply or Sign up for a free account.