I need to validate password with these requirements:-
And got stucked a bit, here's what I have so far.
<form>
Password <input type="text" pattern="/^[a-zA-Z0-9!@#\$%\^\&*_=+-]{8,12}$/g" />
<input type="submit" value="Submit" />
</form>
JSFiddle
try this pattern
^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[!@#$%^&*_=+-]).{8,12}$
Demo
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With