I am learning how HTML5 pattern works, and I am trying do a email field validation.
The problem is that when I add the '@' in the pattern, when I try, the field does not consider it valid. If I try the pattern without '@' works perfectly.
Requirements of the validation:
-> starts with 5 characters or numbers
-> then goes an @
-> continuous with a range between 2 and 10 characters or numbers
-> then .
-> must have 'es', 'org' or 'com'
CODE:
<input type="text" name="email" id="email" pattern='^[a-zA-Z0-9]{5}@[a-zA-Z0-9]{2,10}.(es|com|org)$'>
PD: I know the email field exists, but I'm testing the html5 patterns.