- 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
They are discriminating against people older than 99. I mean, babies are allowed, but old people are not? :(
Admin
Notice that the ZIP function will succeed without checking the input if a hidden field on the form is set to "sverige" (Sweden), ignoring case.
Because, you know, Sweden is the only country that doesn't use a ZIP code.
Admin
clearly, the swedish do not make mistakes when filling out online forms.
also: chocolate.
Admin
But what if your 100+ years old and want to join?
Admin
No, the other way round. They only validate Swedish ZIP codes, which actually makes sense.
The real WTF however is that they use regular expressions /1/../9/ instead of one /[1-9]/.
Admin
Admin
If all you have is a hammer, everything looks like a nail.
If all you have is scientology, all of your input looks like body thetans, and it needs to be purged.
Admin
No wonder so many websites will allow 000-000-0000 as a valid phone number.
Admin
I think that was Groucho
Admin
TRWTF is the
starting from line 456.
Admin
When would s.substr(1,1) > "9" ever be true?
Admin
Couldn't they have at least taken all the replacement code out into another function if they were going to use it so much?
Admin
No, they wanted /^[0-9]{5}$/ /[1-9]/ makes sense only if 9999999 is a valid Zip Code.
Admin
Maybe they don't want a bunch of old people in their scientologist group. They wouldn't be missing anything.
Admin
Nope, babies, and kids under 10 are not allowed either. Two digits are required, but when age starts with a "0", it gets discarded as well.
Admin
Well damn. I filled out the whole ridiculously long 200 question questionnaire, and of course I didn't get anything for it, but they will call my number to tell me the results. The WTF is: only land lines, no cell phones.
Not that I gave any of my info of course, and if they send any emails, I hope [email protected] will be happy :D
Admin
So any character of this list:
Also known asAdmin
You have to pay for more training in order to be enlightened and fully understand the hidden obfuscated powers of what seems to be silly javascript but is not.
And thetans.
Admin
The Real WTF is Scientology
Admin
As always, the boggling part is: if they know how to match using /\d/, then why don't they know how to match using /^\d{5}$/ ?
Admin
Actually, it says val != "sverige" return true. Thus if the person is from Sweden, they require checking, otherwise they know what they're doing.
Also, last time I checked, substr(1,1) returned "".Admin
/^\w+([.-]?\w+)@\w+([.-]?\w+)(.\w{2,3})+$/ (line 400)
Admin
K, then since all they really seem to care about is whether a string of characters are numbers, can't they just loop through each string to see if each substring is between "1" and "9"? I mean, they do this anyway...
Admin
Are non-zero numbers the equivalent of thetans? Maybe that's why these algorithms remove them. Just my 0 cents (thetans purged).
Admin
Seriously though, does anyone else have the feeling that they are all laughing at us. Tom Cruise and John Travolta are sitting at dinner saying things like "I can't believe people are joining us!", "We can make people do ANYTHING because we are celebrities!" and "This is more fun than taking stands on politics!".
It really must be an elaborate joke. No one can really believe such things...
right?
Admin
shees.
Admin
String.substr(index : Number, length : Number) : String
So no, substr(1, 1) returns a single character at index 1.
Admin
haha must be one of the greediest companies still in existance :)
they dont have enough money to hire someone who UNDERSTANDS what they do
Admin
The real WTF is that their checking won't allow anyone to be older than 99...
Admin
It is not surprising that a Scientology site doesn't allow people younger than 10 or older than 99.
These groups must have been ruled out as revenue sources.
Admin
Regexes are actually a conspiracy of the evil software conglomerates.
Admin
teh rofl
Admin
Volmarias, you made me lol. Good show.
Admin
I have a theory about celebrities in Scientology. Whether they believe the myths of Scientology or not, their practice of "auditing" has the effect of training you to keep your cool when being harassed. That's an especially valuable skill for those constantly in the spotlight.
Admin
So instead of meditating they believe in aliens stuffing volcanoes?
Admin
awesome? no. ingenious? maybe. amateur? definitely.
all this nonsense: s = s.replace(/1/g,"0"); s = s.replace(/2/g,"0"); s = s.replace(/3/g,"0"); s = s.replace(/4/g,"0"); s = s.replace(/5/g,"0"); s = s.replace(/6/g,"0"); s = s.replace(/7/g,"0"); s = s.replace(/8/g,"0"); s = s.replace(/9/g,"0");
can be replaced with: s = s.replace(/\d/g,"0");
not that i'd do it that way in the first place... i guess the thetans made them do it.
Admin
er... I think it was a quote from Groucho Marx.
Admin
In all seriousness, no, the Scientology organization is not interested in old people. They tend to discard the old and sick members once they are no longer of use to Scientology, and they focus on recruiting the young and rich.
Admin
Ok. If I ever saw ANYONE writing code at my company like this, I would fire them immediately.
Even if I wasn't their boss and I technically couldn't fire them, I would still fire them.
Admin
only l.ron hubbard is allowed to be 100 yrs old or greater
Admin
Oh my, they have good code! They must be evil!!!
Stop the anti-religion bullshit. Our time would be better spent on things that matter (like the wars, the economy, the election), rather than sensationalist bigotry crap.
Admin
It may be anti-religion BS, but it's not bigotry. People can't choose to be white, black, female, asian, or eskimo. So making fun of that is bigotry. People can choose what they believe (well, there are unfortunately exceptions in many places). If you have the freedom to believe, and you believe something stupid, you shouldn't be immune from reasoned ridicule.
Admin
You should be careful with that code. It's probably copyrighted, patented and trademarked Religious Technology.
They don't trust "wog" technology made by non-Scientologists, so they have to do everything their own... unique ... way. I'm just waiting for them to send some kind of infringement notice and threaten to sue the site for 'injuring their reputation of being non-litigious' or something.
If possible, I suggest giving them Mandatory Fun Day as a compromise rather than going to court. It's the sort of thing a Scientologist might enjoy.
Admin
I guess people living past 99 breaks some kind of Hubbard law.
Admin
Where the hell is 'sverige'?
Admin
I'm offended you referred to scientology as being a religion. It's an insult to religion.
Admin
Well, seen from an objective distance, many other world religions are not much less ridiculous than this one...
Admin
Proper input validation closed due to thetans. TRWTF is that anyone is surprised by this... after their sites got hacked, I mean DDOS'd, by teenage punks (before a more legal protest movement stepped in and replaced DoS'ing and blackfaxing), they called in consultants by the droves. Hearsay was that their systems were five years behind on security and defense (i.e. malware).
I guess before they pissed off the younger contingent of the Internet (i.e. 4chan) with that whole "yank the 'Tom Cruise laughs like a crazed slave and babbles' video" stunt, they just had old-timers picketing outside their buildings and talking smack about them on alt.religion.scientology.
Admin
Scientology: $325,000.
Admin
someone reads Raymond Chen's blog in here? =) anyway, i like the method... it's similar to what i would do if i were too lazy to look for VB's IsNumeric function equivalent in JavaScript. (and to be honest, i really don't know the funcion name in JS O:-))