Tylor Eddy Posted March 9, 2011 Report Share Posted March 9, 2011 G'day All, I'm looking for some support in changing the websites timezone to a local timezone, i have consulted support on the issue, but they refuse to help me, saying its not their problem. I have tried editing the local.config.php file with this echo(date_default_timezone_set("Australia/Sydney")); and Config::Set(date_default_timezone_set("Australia/Sydney")); both have been unsuccessful, how do i got about setting the website timezone properly ? Any help would be great because currently, all my schedules are 8 hours behind. Quote Link to comment Share on other sites More sharing options...
Guest lorathon Posted March 9, 2011 Report Share Posted March 9, 2011 Try this. I would say try it out in the local.config.php file http://php.net/manual/en/function.date-default-timezone-set.php Quote Link to comment Share on other sites More sharing options...
Guest lorathon Posted March 9, 2011 Report Share Posted March 9, 2011 Or are you referring to the timezone of MySql? Quote Link to comment Share on other sites More sharing options...
Tylor Eddy Posted March 9, 2011 Author Report Share Posted March 9, 2011 Or are you referring to the timezone of MySql? im not sure, im referring to the timezone that is affecting my schedules, not sure if there are timezones running different things anyways i used this: bool date_default_timezone_set ( string $timezone_identifier ) do i include bool ? Thanks for the help so far, hopefully i'll have this resolved shortly ps. i just tried it with this: bool date_default_timezone_set ( string Australia/Sydney ) and the site wont open, unsure why, all i got was a white screen. Quote Link to comment Share on other sites More sharing options...
Guest lorathon Posted March 9, 2011 Report Share Posted March 9, 2011 You have to look at the examples. Try adding the following to the local.config.php date_default_timezone_set('Australia/Sydney'); Quote Link to comment Share on other sites More sharing options...
Tylor Eddy Posted March 10, 2011 Author Report Share Posted March 10, 2011 You have to look at the examples. Try adding the following to the local.config.php date_default_timezone_set('Australia/Sydney'); I just tried the code you suggested but it still ticks over at 4PM my time, which is midnight in America, this is being rather painful Thanks for the help so far though lorathon, much appreciated. Quote Link to comment Share on other sites More sharing options...
Moderators mark1million Posted March 10, 2011 Moderators Report Share Posted March 10, 2011 Did you restart apache? Quote Link to comment Share on other sites More sharing options...
Guest lorathon Posted March 10, 2011 Report Share Posted March 10, 2011 I believe you will need to change the MySql timezone. To do this you will need SUPER privileges. http://dev.mysql.com/doc/refman/5.5/en/time-zone-support.html Quote Link to comment Share on other sites More sharing options...
Moderators mark1million Posted March 10, 2011 Moderators Report Share Posted March 10, 2011 If you have access to your php.ini you should be able to change from there, if not try creating a file called php.ini and putting the following in your website root, then restart apache or iis. date.timezone =Australia/Sydney Failing that try this, http://www.electrictoolbox.com/php-change-timezone/ Quote Link to comment Share on other sites More sharing options...
Tylor Eddy Posted March 15, 2011 Author Report Share Posted March 15, 2011 If you have access to your php.ini you should be able to change from there, if not try creating a file called php.ini and putting the following in your website root, then restart apache or iis. date.timezone =Australia/Sydney Failing that try this, http://www.electrictoolbox.com/php-change-timezone/ Sorry for my delayed reply, I have tried all recommended settings except the mysql one, and am not sure how to restart apache, is that the reason why it isnt working ? Sorry if the answer is starring me right in the face, i still havent seen it yet Cheers Guys Quote Link to comment Share on other sites More sharing options...
Jeff Posted March 23, 2011 Report Share Posted March 23, 2011 Bump! Quote Link to comment Share on other sites More sharing options...
Moderators mark1million Posted March 23, 2011 Moderators Report Share Posted March 23, 2011 If you have access to your php.ini you should be able to change from there, if not try creating a file called php.ini and putting the following in your website root, then restart apache or iis. date.timezone =Australia/Sydney Failing that try this, http://www.electrictoolbox.com/php-change-timezone/ After trying this you need to restart your apache / iis or what ever you are using. What access do you have to your server? Quote Link to comment Share on other sites More sharing options...
Jeff Posted March 23, 2011 Report Share Posted March 23, 2011 I am using fivedev. I cannot find the location to the php.ini file, and I do not know how to reset the apache. I am wanting to set it to Europe/London Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.