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

12345 could be a valid postcode in Germany or Spain, but in the UK it would have to look like AB1 2CD, except when it doesn't (e.g. AB12 3CD). Arg!

I wish web forms had a "Tell us we are wrong" button next to validated boxes.




    I wish web forms had a "Tell us we are wrong" button next to validated boxes.
You know... that's a very good idea actually.


I've been thinking about service that injects some lines of javascript for client sites that gives them button "fix this". It would send warning email after few messages about typos but it could also be used to fix these kind of things. Not sure how JS could handle selection and button press simultaneously. Maybe copy+paste part of page with fix. Maybe get some reward for being grammar nazi. Maybe some paid service for auto checking if corrections are accurate and auto-inject corrections to sites.

What the heck, how can I take MS Word online?


There's also the problem of "validation rot" in which validation functions can be correct today, but might not get updated if the data format changes.


FWIW, UK postcodes have a very strict and well defined format:

https://wikipedia.org/wiki/Postcodes_in_the_United_Kingdom#F...

Also, something not many people know is that any postcode in the UK has a maximum of 100 addresses in it.

You can tell I've been writing a search algorithm for UK address data recently ;)


I'd like to think that's not rare enough for websites to have assumed they were always six characters - half of London lives in postcodes like "N1 2BC". The bigger problem I've found with postcodes was sites insisting on five digits, or even insisting on postcodes at all - not every country uses them!




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

Search: