<input type="password" class='reg-inp' id='password' name='password' > <input type="password" class='reg-inp' id='confirm_password' name='confirm_password' >
- Really those who use jquery can't do simple validation without third-party plug-in? O_o Pechalko and only - Zowie
- I would give it without problems if I had a question how to implement validation, the question is about the jquery plugin, I don’t know the answer to your question, but I’m not going to google for you, any more questions? - Zowie
|
1 answer
Check without plugins. Password form
<form method="post" name="formZ" id="formZ" action=""> <fieldset> <input type="password" name="passwordX" id="passwordX" /> <input type="password" name="passwordY" id="passwordY" /> <input type="submit" value="submit" id="submit"> </fieldset> </form>
Code for checking values:
$("#submit").click(function () { $(".error").hide(); var valueX = $("#passwordX").val(); var valueY = $("#passwordY").val(); if (valueX != valueY) { alert("Passwords do not match."); } });
Now check with the plugin :
$("input[type='password']") .equal("Passwords do not match.");
- Found info where? TC claims that there is no info in Google - Zowie
|