I've a text field.
I'm to type the email in it.. eg. username@domain.com

What I want is that, as soon as the user types the char "@", the remaining part of the string gets masked so that it appears to the user viewing as username@\*\*\*\*\*\*\*\*\*\*

But in the backend, the real keys typed has to be captured somehow.

Is there a way to do that using javascript?