Created
May 20, 2020 10:39
-
-
Save attilaking/742f7b68257dff9dcd9200df9c630feb to your computer and use it in GitHub Desktop.
[Validate email] email validations #email #validate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ValidateEmail(mail) { | |
if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(mail)) { | |
return (true) | |
} | |
//alert("You have entered an invalid email address!") | |
return (false) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment