-
Improvement
-
Resolution: Won't Fix
-
Major
-
None
-
2.0
-
None
-
PHP5 & MySQL running on Linux servers.
-
MySQL
-
Easy
-
MOODLE_20_STABLE
Any bookings made prior to change to DST will have to be fixed using SQL. In tests, the following code (taken from version 1.4.1) fixes the problem for future time changes:
in web/config.inc.php the following needs to be added:
-
-
- snip --*
-
// The timezone your meeting rooms run in. It is especially important
// to set this if you're using PHP 5 on Linux. In this configuration
// if you don't, meetings in a different DST than you are currently
// in are offset by the DST offset incorrectly.
//
$timezone = "Europe/London";
-
-
- snip --*
-
If your server timezone is not that above, you will need to edit that line. q.v. http://uk3.php.net/timezones for those available.
in web/functions.inc the following needs to be added near the top of the file:
-
-
- snip --*
-
/////////////////////////////////////////
// Set timezone, if one has been provided
global $timezone;
if (isset($timezone))
{
if (function_exists("date_default_timezone_set"))
{
date_default_timezone_set($timezone);
}
else
{
putenv("TZ=$timezone");
}
}
-
-
- snip --*
-
I've tested the above by changing server dates on an Ubuntu server and making bookings before and after this year's DST period and everything behaves properly now.
- is duplicated by
-
CONTRIB-2144 MRBS block: Follow up BST time change issue messing up times
- Resolved
- will be (partly) resolved by
-
CONTRIB-1671 Force Booking function doesn't move bookings with DST timeshift applied
- Resolved