Hacker News new | ask | show | jobs
by microtonal 4664 days ago
Nope, you should still validate your input. The correct thing to do is the validate that the input is semantically valid rather than syntactically valid. If they enter an address, try looking it up.

We rented a newly constructed house. The old houses in that area were demolished, but the same street names were kept. It was very annoying to have web forms doing such validation telling me that the address was invalid (you cannot have that house number in that street).

Another pet-peeve: I have an ë in my name. When I purchase some software through a web form that accepts that character, please don't just remove it or replace it with garbage in my license key ;).

2 comments

I had the same problem getting internet to my rented office space. The ISP didn't have an updated db with the building's new office numbers.

I had to call and talk to someone put in a work-around. That meant I lost the discount for doing it over the web. It also meant that it took months and several phone calls for the bill to start coming to the right place.

Perhaps the message should be- "please double-check, we can't find a record of that <> in our database." But accept it if the customer insists.

this looks a bit different from the other side. When I worked at in a big retail shop we had to have forms (ie. zip/city) validation. There was a time when validation was as simple as proposed in the article (checking for presence of data, not the meaning). You wouldn't believe the things people are able to type into forms.

One of the most common errors was a bad combination of zip/city (ie. zip code for a different country area) which required a live person on the phone asking customer about proper data - it costed money.

The most unusual one was when a person managed to type gibberish in every field avaliable and than add to it a proper adress, name, zip etc... all in a three or four letter wide house-number box.

VALIDATE ALL THE THINGS!

> a three or four letter wide house-number box

That sounds problematic to begin with. I grew up in a house with a 5-digit street number.