Re: Convert local dates into GMT+1 dates

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



debussy007 wrote:
Hello everyone!

I have local dates (Belgium), which I want to convert to GMT+1 date.
The dates are stored in the DB and are of the following format:  '2008-06-24
23:30:02'

So I think I'll need to check wether the date in DB is GMT+1 or GMT+2
(winter or summer),
if date is GMT+2, subtract one hour from the date.

Thank you for any help achieving this !!

Surely this shouldn't be an issue and that's what timezones are for? if your timezone is set up correctly on server then DST will be auto handled for you?

get the date as UTC, always store as UTC, then present as whatever timezone you want; thus your time is always accurate regardless of DST.

(I hardly understood what I just wrote, but I know what I mean).

Regards!

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux