Can anyone tell me on what's wrong here in the password field validation
.I am checking for password strength
, regardless of what ever i enter it always says "password must contain atleast one number and one character"
jQuery.validator.addMethod("pwcheck", function(value) {
return /^[A-Za-z0-9!@#$%^&*()_]$/.test(value) // consists of only these
&& /[a-z]/.test(value) // has a lowercase letter
&& /\d/.test(value) // has a digit
}, "password must contain atleast one number and one character");
I want to check my password field allows at least one number, one character and any number of specialcharacters/numbers/characters.