I found that all events were displaying the UTC offset rather than the timezone abbreviation. I’m not sure if this is specific to us, or if it is common. After a bit of research, I found that there is a more reliable method to finding the abbreviation than simply passing it to the DateTimeZone class.
These are the changes made to more reliably get the abbreviation:
In Timezones.php, change the abbr function:
public static function abbr( $date, $timezone_string ) {
try {
if (strpos($timezone_string, 'UTC') === 0) {
$offset = substr($timezone_string, 3);
// Calculate seconds from offset
list($hours, $minutes) = explode(':', $offset);
$seconds = $hours * 60 * 60 + $minutes * 60;
// Get timezone name from seconds
$tz = timezone_name_from_abbr('', $seconds, 1);
// Workaround for bug #44780
if ($tz === false) $tz = timezone_name_from_abbr('', $seconds, 0);
$tz_date = date_create($date, new DateTimeZone($tz));
$formatted = $tz_date->format('T');
return $formatted;
}
$tz_date = date_create($date, new DateTimeZone($timezone_string));
$formatted = $tz_date->format('T');
return $formatted;
} catch (Exception $e) {
return '';
}
}