Entrepreneur Geek

Nirav Mehta on life, technology and future

* is ok in an email

with one comment

http://en.wikipedia.org/wiki/Email_address
According to RFC 2822, the local-part of the e-mail may use any of these ASCII characters:

  • Uppercase and lowercase letters (case insensitive)
  • The digits 0 through 9
  • The characters, ! # $ % & ‘ * + – / = ? ^ _ ` { | } ~
  • The character “.” provided that it is not the first or last character in the local-part.

i.e. Acording to RFC 2822, _firstname.lastname@domainname.tld or #firstname.lastname@domainname.tld are 100% correct email address.

Standard Regular Expression for any email according to RFC 2822,

/^(([a-z0-9!#$%&*+-=?^_`{|}~][a-z0-9!#$%&*+-=?^_`{|}~.]*[a-z0-9!#$%&*+-=?^_`{|}~])|[a-z0-9!#$%&*+-?^_`{|}~]|(“[^"]+”))[@]([-a-z0-9]+\.)+([a-z]{2}|com|net|edu|org|gov|mil|int|biz|pro|info|arpa|aero|coop|name|museum)$

Also Visit : http://tools.ietf.org/html/rfc2822

Thanks to Vikas, who works in our PHP team, for this! I didn’t care to read this much about emails!

No related posts.

Written by Nirav

September 20th, 2006 at 12:21 pm

Posted in Technology

 

One Response to '* is ok in an email'

Subscribe to comments with RSS or TrackBack to '* is ok in an email'.

  1. Devdas

    20 Sep 06 at 10:02 pm

Leave a Reply