Hacker News new | past | comments | ask | show | jobs | submit login

Here is some handy regex:

/^([\w\!\#$\%\&\'\\+\-\/\=\?\^\`{\|\}\~]+\.)[\w\!\#$\%\&\'\*\+\-\/\=\?\^\`{\|\}\~]+@((((([a-z0-9]{1}[a-z0-9\-]{0,62}[a-z0-9]{1})|[a-z])\.)+[a-z]{2,6})|(\d{1,3}\.){3}\d{1,3}(\:\d{1,5})?)$/i




Apparently, you need something like this to fully comply with the RFC: http://www.ex-parrot.com/~pdw/Mail-RFC822-Address.html

Or you can just do some basic checks and verify it by sending an actual email.


Or just check for an @ symbol and use confirmation email.


It's worth hesitating before introducing a confirmation-email step. You're certainly going to lose people every time you increase the complexity of the signup process.


In some countries (EU?) you're required to do a confirmation-email step.


MX/A records can be useful for this as well.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: