Page 1 of 1

Wrong arithmetics with date()

Posted: Sat Aug 10, 2002 4:55 am
by mimcris
Hi!
Look at this statement:

print date("i:s", 3599); // result -> 59:59 - right!

print date("H.i:s", 3599); // result -> 01.59:59 - wrong of course!

print date("H.i.s", 3600); // result -> 02.00:00 - Crazy or not!
I've tried with many params but it seems that the hour value is always shifted 1 ahead.

Anyone can help?
Tks
Mimmo

Posted: Sat Aug 10, 2002 12:07 pm
by firepages
then try a more valid timestamp

print date("i:s", 00000000003559);
print date("H.i:s", 00000000003559);

I also get +8 but I assume thats my locale

I assume you are GMT +1 ??