Skip to content

Instantly share code, notes, and snippets.

@6qat
Created November 20, 2012 14:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 6qat/4118386 to your computer and use it in GitHub Desktop.
Save 6qat/4118386 to your computer and use it in GitHub Desktop.
JavaScript: Check valid e-mail
function is_valid_email($email)
{
if(preg_match("/[a-zA-Z0-9_-.+]+@[a-zA-Z0-9-]+.[a-zA-Z]+/", $email) > 0)
return true;
else
return false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment