I hate JavaScript

Today, I run into a JavaScript problem… I do have a calendar on some web pages, and wanted to initialize the calendar to the day before the current time. This turned out to be broken because of the fact that the JavaScript Date object indexes months not on 1 but on 0! Yep. You’ve got it: 1 mean February and not January!! Who in the hell proposed such a thing? Days and years are not even indexed by 0, so there is not even coherency…

One Response to “I hate JavaScript”

  1. David Says:

    C’est la meme chose pour la classe Calendar en Java si je ne m’abuse.
    Donc c’est qu’il doit y avoir un standard ;)

Leave a Reply