Log in

No account? Create an account

Previous Entry | Next Entry

Email Address Validation

Email address validation always seems to be difficult. In reality, it's not difficult, it's just tedious. I tend to find a lot of broken email validators because my email address is a bit less than common.

Today, I was using the "Contact Us" Form at my credit union and ran into a validation error on my email address. I had a little time, so I decided to look for the javascript that was causing the problem. I found it, and it was pretty easy to spot, so I decided to send the credit union another message:

My email address (greg@cohoon.name) is reported as invalid by this form. Please submit a bug report to your developers and have them correct the logic in the "isEmail" javascript function on the https://www.truliantfcu.org/includes/validations.js page. Currently, assumption #4 is incorrect, as not all TLDs are simply 2 or 3 characters. To get around the ".name" issue, the following code can be used for the last portion of "reg2":


However, fixing the code in that manner would still cause it to consider addresses ending in ".info", e.g. to be invalid. A better solution would be to determine the actual rules governing the naming of TLDs and implement a correct validation algorithm.

It looks like you have the same bug in the "isURL" function.

I'm interested in seeing what sort of customer service response a "contact us" message like this will generate.

Ironically, I am currently wearing my "No, I will not fix your computer." shirt.


( 5 comments — Leave a comment )
Oct. 7th, 2007 11:30 am (UTC)
I used to have a "No, I won't get you backstage" shirt.
(Deleted comment)
Oct. 7th, 2007 06:57 pm (UTC)
It was custom-made. I used to work at a number of big arena concerts in between my regular gigs, and I occasionally experienced being set upon by folks eager to get access to celebrity rock-n-rollers. I thus got the shirt made and found it worked wonders.
Oct. 7th, 2007 12:39 pm (UTC)
Ironically, I am currently wearing my "No, I will not fix your computer." shirt.

Thinkgeek.xom ia awesome
Oct. 7th, 2007 05:51 pm (UTC)
I <3 computer geeks.
Oct. 7th, 2007 06:58 pm (UTC)
My employer is a (dot)aero .aero

Most places still are not accepting that as an e-mail domain
( 5 comments — Leave a comment )

Latest Month

June 2013
Powered by LiveJournal.com
Designed by Tiffany Chow