- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Admin
Admin
His bad mood is the direct result of a few people telling him that his jokes are not funny and the power outage they are currently experiencing there.
Admin
Additionally, Client Side validation simply requires users to enter more realistic-looking data which is harder to discern from real data.
Example: I have an unvalidated form that I need to fill in:
vs the Validated form
A human can see both of these are likely bodge, but because the computer has forced the 2nd to be in a format it considers valid, it can't see that it's a crock.
The only time the user needs a response like "invalid zip code/phone number" is if they would be expecting an immediate response. If (as is usually the case) they are sending feedback or subscribing to something, you let them think everything is hunky dory and can choose whether to pay attention to their rubbish or not....but this is a decision that is made at the time the data is used not at the time the data is entered....
Admin
Admin
For shame,
Noone has yet mentioned "You Midas well have the best".
Admin
Yeah, its really time consuming to unscrew a bolt and filter, screw them back on, and dump some oil in.
Admin
Also, as usual, Opera could already edit pages live before "Inspect Element" was even invented.
Admin
Also interesting how |0|1|1 is also a valid zip-code... I've never seen zip-codes with pipe symbols before ^^
Admin
I'm betting the compiler complained that "\d" wasn't a valid escape code. The fix for that is to remove the "" of course!
Admin
(Thank you for regurgitating Wikipedia, you get a B+ on your 3rd grade book report.)
Admin
luxembourg?
and my comment is not (that much) spam... akismet!
Admin
actually there's two parts to that regex. "a0a0a0" would also work.
broken down into words, the entire regexp is:
5 d's at the start of the string followed by an option hyphen and 4 d's at the end of the string.
or
any letter at the start of the string, followed by a numeral, followed by any letter, followed optionally by a hyphen, followed optionally by a space, followed by a non-optional numeral, followed by any letter, followed by any numeral at the end of the string.
Admin
dnn_ctr685_UIComponentInjector_ctl00_ZipPostalCodeRegEx.validationexpression = "(^[0-9]{5}(-[0-9]{4})?$)|(^[ABCEGHJKLMNPRSTVXY|abcdeghjklmnprstvxy][0-9]A-Z|a-z?( )?[0-9][A-Z|a-z][0-9]$)";
Admin
My total peeve is when my bank will not accept as input my account number ENTERED EXACTLY AS THEY DISPLAY IT THEMSELVES. You show it with hyphens, you should accept it with hyphens.
Admin
TRWTF is ASP.NET, which is what the site uses.
Admin
Admin
Pfff.... just get annected by next biggest neighbor and be done with that attitude. It's fun! Ask Tibet!
Admin
Admin
Many gas stations in the U.S. allow you to pay by credit card if you enter a zip code which is annoying for foreigners. The attendants don't seem to understand why you might want to pay by card but not at the pump...
One day I decided to try a zip code of 00000 - and it worked. I chose not to think too hard about that.
Admin
Admin
ahh, the "code" was written in a WYSIWTF IDE
Admin
Seeing as Iceland the population of Iceland is 320 000, not 420 000, it's almost certainly not Iceland.
Admin
according to http://www.worldatlas.com/aatlas/populations/ctypopls.htm
the country with the population closest to 420K is Malta.
Admin
I doubt, though, that each parking space would have its own postal code, particularly because mail is not usually delivered to parking spots.
Admin
the true WTF is that people are stupid enough to say things like this.
Admin
The real WTF is that the guy is going to Midas.
Admin
We don't (even) need no feelthy steenking cities.
Here in "Disneyland with the death penalty" we are tired of the world (not to mention it's dog)'s insistence that we enter Country = Singapore State = Singapore City = Singapore
(oh, and with one 70th of the population of 'murka, we apperently need one more digit in our zip codes, which is probably similar to their being enough IPV6 addresses to give one to every star in the universe (aka, my as shas its own zip code))
Admin
Admin
I once came across a site which used 000+[country dialing code] (or 00+[country dialing code]), i.e. 00044 for the UK, for non-US locations, so I now try this every-time I need to enter a ZIP code.
If they don't accept that (as often they will not), I use the one zip code most people outside the US will have heard of... 90210.
Admin
Admin
Yeah to point 1. Unless you've studied the code, you have no idea what the Javascript does. It may just do some validations that aren't needed if you manually insure that there are no errors ... or it may be massaging the data in any number of ways before submitting the form, doing Ajax calls that fire related updates, etc etc.
As to point 2: You could always copy the web page (and any attached script files, style sheets, etc) to your local drive, study the Javascript, and edit it to fix the errors. But wow, that sounds like a lot of work just to submit an order. Before you can order their products, you have to debug their ordering system?
Admin
So instead of being far-sighted, it is short-sighted; now the USPS won't be able to have a planet code in snailmail barcodes without creating mass confusion. No wonder the mail to Ceres never arrives on time!
Admin
Hmm. So if the user's phone number is, say 123-555-9876, but he slips on the key entering it and it comes in as 123-555-986, you want to just accept it without warning, and somehow figure it out later? How? How do you find what the missing digit was? Okay, maybe you don't really need the phone number. But in that case, why did you ask for it? I think we can safely assume that at least SOME of the data requested on a form is required.
Of course a format validation will not prevent all possible errors. If someone's zip code is 12345 and they accidentally type 12346, a format check won't catch that. But a format check will catch SOME errors, and some is better than none.
Admin
Oh, follow-up to my previous post.
You talk as if the only point of data validation is to distinguish serious entries from spam. I can certainly understand the desire to filter out spam. But presumably the main point of, say, an order processing system, is to GET ORDERS so that we can collect money and ship merchandise. It's not enough to determine that an order is indeed a real order and not spam. We'd also like to collect enough information so we can actually get their money, and if we don't want to be forced to refund their money, we probably need to collect enough information to actually ship the merchandise the customer wanted.
So sure, if someone types in "up yours" as a credit card number, then if we just accepted it, the jokester will have his laugh and we can safely disregard the order. but if someone types in a credit card number that doesn't have the right number of digits or doesn't pass the check-digit rule, it's quite likely that this was just a typing mistake and not spam. In that case, it seems like a good idea to alert the user that the credit card number entered is invalid so he can fix it, rather than just accepting it and later saying, Oh well, invalid credit card number, I guess we'll just throw away that order.
Admin
It may surprise you, but you DO live in a state. What the hell to you think a country/nation is?
God, when will we get some educated people on this board?
Admin
On the slightly serious side: Does anyone know why the IPv6 space is so huge? I mean, I can understand wanting to give plenty of room for future expansion and allowing for some dead space because we want to give out numbers in blocks. But with 6 billion or so people in the world, even if every person had 1000 devices, that would make 6 trillion, which would require ... quick calculation here ... 34 bits. So round it up to 40 to make an even 5 bytes. Or round it up to 48 to make an even 6 bytes. Even round it up to 64 so it takes up a long integer as defined in many languages. But 128? Isn't that rather a lot of overkill?
Hey, quick calculation: There are 6e23 molecules per mole. Say the average person weighs maybe 80 kg. People are mostly water (over 90% I think I've read), which is 18 grams/mole, most other stuff in a person would be heavier, so conservatively a typical person should be less than 80,000 / 18 ~= 4,400 moles. 4,400 moles * 6e23 molecules/mole = 2.6e27 molecules. Times 6e9 people means there are about 1.6e37 molecules of people in the world. IPv6 address space is 3.4e38. So the IPv6 address space is big enough to give a separate IP address to every molecule in the body of every person in the world! That would still have 95% of the space free to accomodate future population growth, beings from other planets, etc.
Admin
Just the kind of thinking I'd think from a small-minded baryonic-matter-supremacist race.
Admin
THERE! The page IS working. One guy got through it.
I'ma go play some Crysis now.
Admin
Living too in a country with only 500,000 inhabitants, we have postal codes for every street (not only per city).
I remember registering at an american site where I had to fill in my address. You could either select your city or type in your zip code. I selected my hometown and it automatically filled in a code, I had never seen. I looked it up and it sure was the postal code of a street in my town. They apparently had randomly selected a street and copied its zip code, mistaken it for the entire city's code. So my address now had a wrong zip code. I changed it to the real one, but the system didn't want to accept it, because it didn't match their code for the town. I checked other towns and they sure only had 10 zip codes for the 10 towns in their database.
We even have a few streets (with more than 500 houses) that have 2 zip codes! One for the even numbered side and one for the odd numbered one.
Admin
Yeah, that's pretty normal. What many people in a country with low-granularity postal/zip codes often don't realise, is that postal codes are no longer really necessary to deliver mail (as the Irish found out, mentioned earlier), but they do have demographic information attached. And you can buy, and more importantly, sell this information.
So with my last address in the Netherlands, with postal code 1083 CZ, not only can you see that it's in Amsterdam, but also that it's in an affluent neighbourhood (in Google Earth/Maps, there's actually an Audi R8 parked in front of the flat), although not nearly as affluent as the apartment block next to it. This means that you can really target your advertising, for example.
Phone numbers is another one. Quite a few sites insist that you fill in an area code. Cool, but area codes with mobile phones are useless (and we don't even have a landline any longer), and in this country we just have eight digits and that's it.
Admin
One more thing India inherited from its former colonial boss, apparently.
Admin
Damn foreigners. Where do they get off being annoyed at zip codes?
Admin
The real WTF is taking your car to Midas for an oil change.
Admin
Severity One : "Phone numbers is another one. Quite a few sites insist that you fill in an area code. Cool, but area codes with mobile phones are useless (and we don't even have a landline any longer), and in this country we just have eight digits and that's it."
That one will go right over the head of most Yankees. They still have landline area codes to their mobiles.
Admin
http://midastucson.com/MidasLocatorV2/TestingPage/tabid/198/language/en-US/Default.aspx
Admin
To be fair, US postal codes get specific down to individual houses as well (though I recently found out the same is not true for apartment dwellings; they seem to be grouped within apartment buildings). The "ZIP + 4" specifies the area postal code and the specific physical location code. Very few online forms require the ZIP + 4 however, tending to only use the 5 digit ZIP. Shipping services, UPS, FedEx, and the USPS, will typically auto-fill the succeeding 4 digits of the full ZIP based on what you enter for a street address.
Admin
Alternate solution: Ctrl+shift+J and paste ' dnn_ctr685_UIComponentInjector_ctl00_ZipPostalCodeRegEx.validationexpression = ".*";' into the console, then type whatever zipcode you want.