c-o-d-e Posted December 14, 2009 Share Posted December 14, 2009 I have read about how to change the timezone in PHPMYADMIN, but it changes back, it doesn't STAY there. If thats not possible, if I had..; $time = date("d-m-Y H-i-s" time()); or.. if I had $time = time(); I think I am 6 hours ahead PHPMYADMIN time. To set it in php.. would it be.. $t = 6 * 3600; // 3600 seconds in an hour, times it by 6. This could be 5 though. $time = date("d-m-Y H:i:s" time()) + $t; // For the current date // Or like.. $t = 6 * 3600; // 3600 seconds in an hour, times it by 6. This could be 5 though. $time = time() + $t; // For the currunt unix timestamp Also, how would I change the PHPMYADMIN default timestamp.. so that when I enter the dates, it'll show up with .. the correct time for GMT-london. Thanks Link to comment https://forums.phpfreaks.com/topic/185097-setting-a-default-timezone/ Share on other sites More sharing options...
PFMaBiSmAd Posted December 14, 2009 Share Posted December 14, 2009 http://dev.mysql.com/doc/refman/5.0/en/time-zone-support.html Unless you have root access to change the system_time_zone or global time_zone, you would need to set the Per-connection time zone using a query in your script before you execute any queries that are time zone dependent. Link to comment https://forums.phpfreaks.com/topic/185097-setting-a-default-timezone/#findComment-977044 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.