Timezones whoops in Iphone and Safari with Daylight Savings
Looping through October dates in 2015 for Sydney Australia, I was finding it weird that I had 32 days ! I'm fairly sure that wasn't how the rhyme went. Anyway, looking into it, turned out that when starting at 1/10/2015 and adding 1 day til the end of the month, you ended up with 1,2,3,3,4 - see an extra day there which seems like Sat showed up twice. Turns out, there appears to be a big in the "Spring Forward" part of the Javascript engin there where Midnight on 4/10/2015 is interpreted as actually being 3/10/2015 at 23:00, go figure. In reverse, 5/4/2015 ("Fall Back") was displayed as 5/4/2015 at 1AM!!!! See the quirks below which appears in Chrome; try on an iPhone to see for yourself. Of course it was already asked over there on at stackoverflow. Date TimeZone Offset Month Day Of Month Time UTC Hours Sun Apr 05 2015 00:00:00 GMT+1100 (AUS Eastern Daylight Time) -660 3 5 1428152400000 13 Sun Apr 05 2015 01:00:00 GMT+1100 (AUS Eastern Dayli...