Posted By

beforebeta on 03/10/08


Tagged

regex


Versions (?)

Who likes this?

7 people have marked this snippet as a favorite

chrisaiv
mikegreen
egoens
dmitryfstyleca
tomasdev
vestimir
configuration


JS Email Validation


 / Published in: Regular Expression
 

  1. function is_valid_email (email)
  2. {
  3. return /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/.test(email);
  4. }

Report this snippet  

You need to login to post a comment.