Handling different timezone
On the shared hosting package I have the timezone is set to Central European Time for the php installation on the web server and the mysql database. I dont have root access to change this however i can alter settings using a php.ini file etc. I want to set both to London time. I was thinking of using this sql statement on every connection to the database:
SET time_zone = '-1:00';
I was also going to set the php time using this statement or alternatively just change it in the php.ini file:
The query I have is I've read somewhere that I will encounter problems when daylight saving changes etc come into play and the difference between CET and GMT isnt 1hr. I read somewhere that even setting the db timezone like this wont resolve this:
SET time_zone = 'Europe/London';
Anybody got any suggestions or guidance? Thanks.
This is how my friend done it.
make a function and make sure your server timezone is GMT
|All times are GMT. The time now is 04:00 AM.|
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0