[nycphp-talk] Date switching back and forth
harvey
list at harveyk.com
Sat Oct 1 09:27:23 EDT 2005
How is this possible? I have a site hosted at Yahoo and am using the
following code to display the date/time at the top of the page. Works
fine, except-- every once in a while, the date is one full day off.
For example, on the 28th of this month at about 10pm, the page said
it was the 29th at 10pm. Later on, it was fine and said the right
date. Yahoo, of course, says it's not them, but what else could it
be? Thanks in advance.
$hourdiff = "-4";
$timeadjust = ($hourdiff * 60 * 60);
echo date("l") . "<br>" . date("F jS, Y") . "<br>" . date("g:i:s a",
time() + $timeadjust) . " NYC";
More information about the talk
mailing list