Regex pattern for validating email for special symbol of ASCII character 146 in domain name as well as in username

19 Views Asked by At

I have used this pattern and after several modification this pattern is not validating and I'm validating by regex.

<input type="email" 
pattern="/^([a-zA-Z0-9_\-\’\.'’]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$/" 
name="user.emailId" placeholder="<s:text name="subc.emailid"/>" required="required" class="form-control" title="<s:text name="subc.emailid"/>" data-toggle="tooltip" data-placement="left"/>

for example I have to validate email id test’[email protected]

And this special character in not present in keyboard.

I've tried several modifications and now I want that email Id Id to be validated.

0

There are 0 best solutions below