mirror of
https://github.com/e107inc/e107.git
synced 2025-08-20 05:11:42 +02:00
Issue #5096 - possible fix for older versions of PHP.
This commit is contained in:
@@ -65,11 +65,13 @@ trait StrftimeTrait
|
||||
return date_format($datetime, $format);
|
||||
}
|
||||
|
||||
|
||||
$timezone = 'GMT'.date('O');
|
||||
$formatter = new \IntlDateFormatter(
|
||||
self::getSensibleLocale(),
|
||||
\IntlDateFormatter::NONE,
|
||||
\IntlDateFormatter::NONE,
|
||||
'GMT'.date('O'), // More accurate timezone. @see https://stackoverflow.com/questions/31707395/why-php-intldateformatter-returns-wrong-date-1-hour
|
||||
$timezone, // More accurate timezone. @see https://stackoverflow.com/questions/31707395/why-php-intldateformatter-returns-wrong-date-1-hour
|
||||
null,
|
||||
$format
|
||||
);
|
||||
|
Reference in New Issue
Block a user