OK don't hate me.. but it's still not right..
According to Australia.gov.au (
http://australia.gov.au/about-australia ... untry/time),
"Daylight Saving Time begins at 2am on the first Sunday in October, when clocks are put forward one hour. It ends at 2am (which is 3am Daylight Saving Time) on the first Sunday in April, when clocks are put back one hour."
This means
April 20, 2013 --> Standard Time
And
Oct 13, 2013 -> Daylight Savings Time
According to
http://php.net/manual/en/function.date.php, I can use I (capital i) to see if the two dates above are within daylight savings or standard time (1 == daylight savings time, 0 == standard time)
Code: Select all
date_default_timezone_set("Australia/Sydney");
$strInputDateTime = strtotime("2013-10-13 00:00");
echo date("I", $strInputDateTime);
// 1 <-- this is right
date_default_timezone_set("Australia/Sydney");
$strInputDateTime = strtotime("2013-04-20 00:00");
echo date("I", $strInputDateTime);
// 1 <-- mmmm.. this is not
am I completely losing my mind?
Self-proclaimed Poor Noob