Page 1 of 1

[solved] server location in different locale: offset time display

Posted: Sun Jan 17, 2010 4:10 am
by kurashiki_ben
Hi all,

My server is located in the EST time zone, and is 14 hours behind my locale (Japan).
I want the time on the site (News, CGComments etc.) to display in the local time here.

I have added the following to .htaccess (in cms root and in admin):

Code: Select all

SetEnv TZ Asia/Tokyo

However, this has had no effect. Times still display in EST both on the front end and the adin area.

Any tips?

Best regards

Ben

Re: server location in different locale: offset time display

Posted: Sun Jan 17, 2010 4:24 am
by kurashiki_ben
solved.

should have read down  :-[:
http://forum.cmsmadesimple.org/index.ph ... #msg109907
On my host it didn't work the .htaccess file, but I was able to overcome this by adding the following line to config.php (I put it under the locale setting line)

putenv('TZ=US/Eastern');

Works just fine in the news date/time etc. Change according to your own timezone.

Code: Select all

putenv('TZ=Asia/Japan');
in config.php did the trick