Email validating regular expression

Edit: I completely forgot the most obvious of all, sending a confirmation e-mail! Yes, this one is pretty foolproof, but it does require extra hassle on the part of everyone involved.The user has to fetch some e-mail, and the developer needs to remember user data before they're even confirmed as valid.

The ending quotation mark must not be preceded by a backslash character (\).

The email’s domain name must start with “A-Za-z0-9-“, follow by first level Tld (.com, .net) “.[A-Za-z0-9]” and optional follow by a second level Tld (au, my) “\.[A-Za-z]”, where second level Tld must start with a dot “.” and length must equal or more than 2 characters.

Here’s a Java example to show you how to use regex to validate email address. [email protected], [email protected], [email protected] [email protected], [email protected], [email protected] 3.

The best option is to ask the user to type their e-mail in twice and if you MUST use a regex checker, then tell the user that their e-mail address does not appear to be valid and ask if they are sure they typed it right.

Even go so far as to point out WHAT did not check out in the regexp check, but do NOT stop them from submitting the form.