Email address validation: please stop
11–20 of 86 posts
Re: Email address validation: please stop
#12I recently changed our email validation: all I do now is check for the existence of an "@".
Then why validate at all? Just send the user an email with an activation link. If it doesn't work and they're still logged into the site (with a limited account), then let them change their email address.
People sometimes misread labels and enter their name on the line for their address. This would stop that.
Re: Email address validation: please stop
#13By including super-special characters and whatever extra features GMail or whoever provides, you're just asking for it, sorry.
Especially if you're a coder yourself, you can already assume that even if it passes the initial validation, it probably won't be properly stored or escaped when the actual mail is sent, when you try to log in with your address later, etc.
Re: Email address validation: please stop
#14One: validating addresses to catch typos. A common example is typing a comma instead of a dot or typing just a username instead of a whole email address. Flagging these errors is a good thing.
Two: some developers believe that they can make people enter real email addresses by being very clever about only accepting strings that look like real email addresses. This is stupid, doesn't work, and often blocks legitimate addresses.
Re: Email address validation: please stop
#15One (very important) site properly validated my "+" email address on the front end (gave me no errors), but the backend failed and I never received the required confirmation email... all resulting in a customer service call. Arggg.
Re: Email address validation: please stop
#16While I agree that some kinds of validation are 'too eager' and annoying, just use a 'legit' e-mail address, ffs. By including super-special characters and whatever extra features GMail or whoever provides, you're just asking for it, sorry. Especially if you're a coder yourself, you can already assume that even if it passes the initial validation, it probably won't be properly stored or escaped when the actual mail i…
Re: Email address validation: please stop
#17Earlier quoted context omitted.
Then why validate at all? Just send the user an email with an activation link. If it doesn't work and they're still logged into the site (with a limited account), then let them change their email address.
If you want your site to have a "login as guest" type feature that's one thing, but if an email address doesn't have an @ it will never work and it would be misleading to encourage people to check their email for a validation link. People sometimes misread labels and enter their name on the line for their address. This would stop that.
Re: Email address validation: please stop
#18Re: Email address validation: please stop
#19On the other hand, maybe the specification for email addresses is too loose.
Re: Email address validation: please stop
#20I tend to rely on http://www.regular-expressions.info/email.html when coming to validate an email address. I do often fall into the trap of trusting the framework's built-in email validation to be correct. Apparently, this is the regex to match RFC2822 (?:[a-z0-9!#$%&' +/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&' +/=?^_`{|}~-]+) |"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f]) ")@(?:(?:[a-z…