1
votes

is there a way to validate passwords without using JavaScript, only html? What i have in mind is that user input should have 8 characters atleast, it should contain number and also "uppercase and lowercase"

<input type="password" id="pass" name="pass">

1

1 Answers

0
votes

you can use pattern for validation and title for a title to show user what to use.

<input type="password" id="pass" name="pass" pattern="(?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{8,}" title="Must contain at least one number and one uppercase and lowercase letter, and at least 8 or more characters">

learn more at : here