• (cs)

    i hope he drapes a hair over his keyboard when he leaves his desk

  • sobani (unregistered)

    strange, I tried my birthday (29 jun 1984), the date in the screenshot and even 31 dec 2007, but none of them generated the error from this article...

  • Obi Wan (unregistered)

    It's an Omen. The true consequences of '1984' haven't arrived yet as described, hence the future reference, hence not a WTF. :P

    Captcha: tesla - futuristic for his time. :)

  • bpk (unregistered)

    Are we finally victimized by the Y2K bug?

  • Anonymouse (unregistered)

    Anyone else think maybe he had his system clock set incorrectly? I don't get it.

  • Nick (unregistered)

    Sheesh, Kind of reminds me of a site that wouldn't let me log in, as "That user name was already in use".

  • (cs)

    My guess is it's the old non Y2k compliant JavaScript thing. The Date.GetYear() function returns varied results for different browsers (translation: microsoft didn't follow the standard).

  • (cs)

    Why are they biased against time travelers?

  • The Fox (unregistered)

    It happens in Safari with any date, but you have to change Safari's user agent to Mozilla or IE to view the page at all. Funny that the error never appears in 'supported' browsers.

  • Yes (unregistered)

    TENTH!!!!! What a day!!!

  • Anonymous (unregistered) in reply to sobani
    sobani:
    strange, I tried my birthday (29 jun 1984), the date in the screenshot and even 31 dec 2007, but none of them generated the error from this article...

    Given that you actually tried a date in the future, it would suggest perhaps they've turned this error checking off already...

  • yafake (unregistered) in reply to Anonymous

    This is soooooo old.

    The issue is with the JavaScript function Date.getYear(), which, by specification, should return the full year. However, MSIE only returns the number of years since 1900. Some stupid "webdesigner" wrote this site without a clue and undiscriminatingly assumed MSIE's wrong behaviour.

    Now, guess where "if Date.getYear() > 108" (2008-1900) leads if a serious webbrowser (like Safari) returns 2007 on getYear().

    sobani simply is an idiot who abuses MSIE as a webbrowser, that's why he can't trigger the bug.

  • (cs) in reply to A Nonny Mouse
    A Nonny Mouse:
    i hope he drapes a hair over his keyboard when he leaves his desk

    The thought police will spot that and carefully replace it exactly as it was:

    George Orwell:
    He put the diary away in the drawer. It was quite useless to think of hiding it, but he could at least make sure whether or not its existence had been discovered. A hair laid across the page-ends was too obvious. With the tip of his finger he picked up an identifiable grain of whitish dust and deposited it on the corner of the cover, where it was bound to be shaken off if the book was moved.

    Not that that did Winston any good either of course...

  • JohnB (unregistered) in reply to The Fox
    The Fox:
    It happens in Safari with any date, but you have to change Safari's user agent to Mozilla or IE to view the page at all. Funny that the error never appears in 'supported' browsers.
    I use Opera ... won't even let me sign up.
  • (cs) in reply to yafake
    yafake:
    This is soooooo old.

    The issue is with the JavaScript function Date.getYear(), which, by specification, should return the full year. However, MSIE only returns the number of years since 1900. Some stupid "webdesigner" wrote this site without a clue and undiscriminatingly assumed MSIE's wrong behaviour.

    Now, guess where "if Date.getYear() > 108" (2008-1900) leads if a serious webbrowser (like Safari) returns 2007 on getYear().

    sobani simply is an idiot who abuses MSIE as a webbrowser, that's why he can't trigger the bug.

    IE returns 2007 for Date.getYear(). It's deprecated with Date.getFullYear() if you want to be picky.

    I suspect this error is an issue with an OLD browser that needs to be updated, as opposed to the "seriousness" of the browser in question. What kind of jackass talks about how serious a web browser is anyways?

  • (cs) in reply to yafake
    yafake:
    This is soooooo old.

    The issue is with the JavaScript function Date.getYear(), which, by specification, should return the full year. However, MSIE only returns the number of years since 1900. Some stupid "webdesigner" wrote this site without a clue and undiscriminatingly assumed MSIE's wrong behaviour.

    Now, guess where "if Date.getYear() > 108" (2008-1900) leads if a serious webbrowser (like Safari) returns 2007 on getYear().

    sobani simply is an idiot who abuses MSIE as a webbrowser, that's why he can't trigger the bug.

    According to the standard, Date.GetYear is supposed to return 2 digits for anything between 1900 and 1999, 4 digits for anything else.

    Now, since their script is presumably taking a 4-digit input (1984) from the user, this error would occur if Safari incorrectly returns 107 instead of 2007.

    Either way, they should be using GetFullYear, but few people do.

  • (cs) in reply to vt_mruhlin

    Now this is making my brain hurt....

    			var selectedDate	= new Date();
    			var now				= new Date();
    			selectedDate.setDate( document.signup.day.selectedIndex + 1 );
    			selectedDate.setMonth( document.signup.month.selectedIndex );
    			selectedDate.setFullYear( document.signup.year.options[document.signup.year.selectedIndex] );
    			
    // ...SNIP...
    			// date
    			if ( selectedDate <= now ) {
    				error			 = true;
    				errorMessage	+= "- Your date of birth isn't in the future.\n";
    			}
    

    Their usage of SetFullYear should be correct. But doesn't (selectedDate <= now) mean that they're explicitly looking for dates from the future? Or do I just need more caffeine? Cause it works in firefox...

  • Ubersoldat (unregistered) in reply to sobani

    Dude! I'm from jun 29th TOO! I'll add you to my calendar

    CAPTCHA: SMILE! It's our birthday... I've felt so alone all this time

  • sobani (unregistered) in reply to yafake
    yafake:
    sobani simply is an idiot who abuses MSIE as a webbrowser, that's why he can't trigger the bug.

    Why are you so mean to call my poor fox such horrible names? Have you no heart?

    captcha: doom, may it happen to you. :P

  • (cs) in reply to vt_mruhlin
    vt_mruhlin:
    My guess is it's the old non Y2k compliant JavaScript thing. The Date.GetYear() function returns varied results for different browsers (translation: microsoft didn't follow the standard).

    The "standard" that existed at the time (i.e. Netscape documentation) was silent on this issue.

    EDIT: I just looked it up. In fact, http://wp.netscape.com/eng/mozilla/3.0/handbook/javascript/ref_f-g.htm#804 is not silent on this matter, rather it specifies precisely the behavior adhered to by IE (tested on 4 and 7), which modern mozilla implementations depart from by returning 107. And the screenshot, incidentally, is of safari.

    Addendum (2007-05-21 15:54): Modern documentation indicates the specified behavior changed with javascript 1.3, and IE simply apparently did not change with it.

    Addendum (2007-05-21 16:04): But the great thing about javascript is that if your script relies on getYear(), you can fix it yourself.

    if(Date.prototype.getFullYear) Date.prototype.getYear = function() { return this.getFullYear() - 1900}

    or, if your script for some reason relies on the old behavior:

    if(Date.prototype.getFullYear) Date.prototype.getYear = function() { if(this.getFullYear() >= 1900 && this.getFullYear < 2000) return this.getFullYear() else return this.getFullYear() - 1900}

  • s (unregistered) in reply to Nick
    Nick:
    Sheesh, Kind of reminds me of a site that wouldn't let me log in, as "That user name was already in use".

    Yep. sharp: username taken sharpy: username taken sharpfn: username taken sharpf: username taken shrpf: username taken shrpfn: username taken shrpfng: username taken ugecwdef: username taken wfcvtfvcfc: username taken wugvbkwhgbc: username taken jhyuhwvbkhwgevbwbvyivcyivcvywif: username taken sharp1: please enter your password.

    Yahoo had this for quite a while: all usernames had to contain at least one digit, otherwise you'd end up with "this username is already in use".

  • PuckeL (unregistered) in reply to sobani
    sobani:
    strange, I tried my birthday (29 jun 1984), the date in the screenshot and even 31 dec 2007, but none of them generated the error from this article...

    If I enter my birthday (28 jun 1984) ;-) I get the error with the system date set to 1984. ^^

  • doc0tis (unregistered) in reply to Anonymouse

    agreed, the user has messed with their system clock

  • (cs)

    lol

    Glad to see this made it on this site.

    I was a software engineer on peepel.com. That error was from implementation AFTER I left the company, I'd like to point out.

    Peepel.com is actually worthy of a WTF article... we had a project manager that was undermined by the director (who was not really good at what he tried to do), myself as the seniormost non-manager, and a couple other engineers that were ok. The project manager was really good, and together we (him more than me...) designed and created most of the people software, with the other 2 developers implementing as per his specification. They did a pretty good job of that too, to their credit.

    The sofware is massive, and the only original developer left is one of the other 2 guys. I sent a letter to the director explaining the shortfalls of the business, and outlined many wrong decisions in terms of marketing and graphical design (cmon, who doesn't think the software graphics look shit). His pride and greed (we had share deals) got in the way and I got fired.

    The project manager quit because of that One of the other 2 developers left to another job offer (more in his field of expertise) The 4th guy is still there.

    I don't know who/if anyone else has been hired, but I know for sure there level of knowledge of javascript, and the framework we wrote, will never equal that of the project manager and myself, so the software is effectively stagnant.

    This date error is the SMALLEST WTF related to peepel.com that I have seen so far.

    Luke Schafer

    Addendum (2007-05-23 02:17): Sorry about the almost ad-hoc nature of this post - I churned it out very quickly (i'm pretty busy) and didn't re-read any of what I wrote

  • minime (unregistered)

    So the real WTF is that Howi didn't left any documentation for his framework?

    Captcha: doom, this is coming really often lately...

  • Sundrop (unregistered)

    Woa, who catches an error condition in the catch section? That is a plain stupid use of try-catch :(

    try {
    	month.add( temp, null ); // standards compliant
    	} catch ( ex ) {
    	month.add( temp ); // IE only
    	}
    
  • Howi (unregistered)

    minime:

    well actually, yes.

    The whole sdlc was extreme programming, and we were pretty much forced to churn out functionality with no time allowed for documentation - another WTF

    so no, i didn't really document my relevant sections (there were comments, but a lot of what I did was rather complex and fairly innovative in regard to how it uses javascript). The framework was not my responsibility, I was more of a consultant on it. Documentation was up to the project manager, but since 'management' (and I use the term loosely) didn't want to hire more people (which we needed), he needed to implement instead of document.

  • Penmonicus (unregistered)

    Wow... That guy was born on the same day as me!

Leave a comment on “Orwell Warned Us”

Log In or post as a guest

Replying to comment #:

« Return to Article