Add pattern validation

Report a typo

The following form has been created. According to the code's description, add the validation for the password input type.

Write HTML and CSS code
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Apply validation</title>
</head>
<body>
<form action="">
<label for="name">Name:</label>
<input type="text" id="name" /><br /><br />
<label for="password">Password:</label>
<input
type="password"
id="password"
title="First two digits from 0 to 8-Next four digits from 1 to 9-Next four digits from 4 to 8"
/><br /><br />
<button type="submit">Submit</button>
</form>
</body>
</html>

Completed 1 of 2
Add required validation to the password input field.
The code is valid.
___

Create a free account to access the full topic