News for hackers. Stuff that matters.
Re:How not to check the validity of an email address by mason240 on Wednesday September 04, 2013 @09:02AM (#6327222)
@"^[^@]{1,}[@]{1}[^@]{1,}\.{1}[^@]{1,}$"

I check it with this RegEx to make sure it's in the right format of [string]@[string].[string] to make sure that user at least tries to enter an email address, but beyond that sending and email and getting a response is the only way.

Re:How not to check the validity of an email address by drdaeman on Wednesday September 04, 2013 @10:35AM (#6327823)
> @"^[^@]{1,}[@]{1}[^@]{1,}\.{1}[^@]{1,}$"

Is not

> [string]@[string].[string]

It's mere ^.+@.+\..+ (in both POSIX extended and PCRE dialects) that properly represents the latter.

And even such regexp filters out many technically-valid but obscure cases of RFC-compliant email addresses (for example ai, io, kh and ws TLDs have MX records, and supposedly hostmaster@io should be a valid email address).