Page 1 of 1

Server Time Offset

Posted: Tue Jan 16, 2007 5:06 pm
by TonyP
Hi all,

Does anyone know whether there is a way to offset the time displayed by CMSMS from the server time?

My server is in PST and my site is used by people in EST so everything (news items etc) show up as being posted 3 hours before they actually were.

I don't see anything in the admin panel or config file that allows this.

Thanks,

T.

Re: Server Time Offset

Posted: Tue Jan 16, 2007 6:27 pm
by cyberman
Have you tried to set locale value in config.php?

Re: Server Time Offset

Posted: Tue Jan 16, 2007 7:24 pm
by TonyP
Thaks for the quick reply cyberman. I did notice that line in config.php but don't know what the options are. Do you know what the $config['locale'] param would be for eastern standard time?

Re: Server Time Offset

Posted: Wed Jan 17, 2007 5:58 am
by cyberman
Take a locale for a country that uses eastern standard time.

For instance - if I wanna german settings I'm including de_DE at the named line.

Re: Server Time Offset

Posted: Wed Jan 17, 2007 9:43 pm
by TonyP
I fixed it by adding the following line to my .htaccess file:

SetEnv TZ location

Where location is selected from a list here - http://www.php.net/manual/en/timezones.php

So in my case the line added was:

SetEnv TZ America/Toronto

Re: Server Time Offset

Posted: Thu Jan 18, 2007 5:24 am
by cyberman
Thx for that.