Skip to main content
Post Made Community Wiki by pera
Source Link
Paolo Bergantino
  • 485.9k
  • 82
  • 519
  • 437

There's something you have to understand the second you decide to use a regular expression to validate emails: It's probably not a good idea. Once you have come to terms with that, there are many implementations out there that can get you halfway there, this article sums them up nicely.

In short, however, the only way to be absolutely, positively sure that what the user entered is in fact an email is to actually send an email and see what happens. Other than that it's all just guesses.