answersLogoWhite

0

function validate(form) {

var e = form.elements;

/* Your validation code. */

if(e['password'].value != e['confirm-password'].value) {

alert('Your passwords do not match. Please type more carefully.');

return false;

}

return true;

}

with a form along the lines of

<form action="..." method="post" onsubmit="return validate(this);">

<label>Password:

<input type="password" name="password" value="">

</label>

<label>Confirm password:

<input type="password" name="confirm-password" value="">

</label>

</form>

User Avatar

Wiki User

14y ago

What else can I help you with?

Related Questions

How do you get the popup javascript box?

Use confirm or alert in javascript code to get a popup


How do you check length of password using javascript?

Use the length property of string in javascript.


How do you use the JavaScript confirm function in PHP?

It has to be done with Javascript. Though you could do something like this:


Can you choose me a password and a confirm password for Minecraft?

You could use 'the5uDrU' as a password, it is considered a 'strong' one due to the use of numbers and different cases. The 'confirm password' is exactly the same thing.


How do you match password and confirm password?

You need to match both or them if it says password and then type it and then if it says confirm and then type your password again


How can one learn how to program the JavaScript confirm dialog box into their code?

There are a number of ways in which one can learn how to program the JavaScript confirm dialog box into their code. One way is by reading the relevant tutorials on the website JavaScript Kit.


What is a comfirm password?

A 'Confirm password' is so that when you type in a password, if you mean ABC123, and you type AbC123 or something like that, the Sign up page will notify you that your password and confirm password are not the same.


What confirm new password?

When you change your password, it will ask you to confirm your password, if you do it two times you are more likely to remember it than just entering it once.


How do you unlock a password for nokia c5-00?

put the password into the password Colum and confirm the password


How do you confirm you password?

function validate(form) { var e = form.elements; /* Your validation code. */ if(e['password'].value != e['confirm-password'].value) { alert('Your passwords do not match. Please type more carefully.'); return false; } return true; } with a form along the lines of &lt;form action="..." method="post" onsubmit="return validate(this);"&gt; &lt;label&gt;Password: &lt;input type="password" name="password" value=""&gt; &lt;/label&gt; &lt;label&gt;Confirm password: &lt;input type="password" name="confirm-password" value=""&gt; &lt;/label&gt; &lt;/form&gt;


What is a confirmation password?

i think it means another password which contains not your name


Write a javascript program to input user name and password?

Just use the &lt;input type="text"&gt; and &lt;input type="password"&gt;. You can also use the prompt() function, but... I'd recommend against it, since it doesn't get censored and is also just plain annoying.