Hello gusy, i've a password field on a edit form, i'd like to view in clear the contained text when i onlick on it.,
Is it possible with javascript?
How?
greetings
Welcome to the nuBuilder Forums!
Join our community by registering and logging in.
As a member, you'll get access to exclusive forums, resources, and content available only to registered users.
Join our community by registering and logging in.
As a member, you'll get access to exclusive forums, resources, and content available only to registered users.
JavaScript code for changing object type onclick Topic is solved
-
- nuBuilder Team
- Posts: 4562
- Joined: Sun Oct 14, 2018 6:43 pm
- Has thanked: 76 times
- Been thanked: 528 times
- Contact:
Re: JavaScript code for changing object type onclick
Hi,
Add this function in your form's Custom Code:
Next, add these two events to your password field:
So, when you click on the password field with the mouse, the characters are unmasked and become visible. When the field loses focus, the characters are masked again.
Add this function in your form's Custom Code:
Code: Select all
function showPassword(element, showPassword) {
element.type = showPassword ? 'text' : 'password';
}
So, when you click on the password field with the mouse, the characters are unmasked and become visible. When the field loses focus, the characters are masked again.
You do not have the required permissions to view the files attached to this post.