I wanted to hide the confirmation of the password and automatically fill it in from the main text field. Here is the code:
<input type="text" size="30" name="password" id="password" value="" onkeyup="document.forms.registr.confirm_password.value=+this.value;" /> <input type="text" class="text" size="30" name="confirm_password" id="confirm_password" value="" />
As a result, when typing the characters a..z in the password field, it appears in confirm_password - NaN, and when entering numbers, everything is fine. I read in the internet about NaN, but I don’t understand why in my case it arises, I’m just copying the value of one field to another. Tell me please?!