The strftime_replacement function now correctly throws objects of type Exception Error.
The combination of format, time zone and locale is now cached to reduce IntlDateFormatter objects and save memory.
Before new \DateTimeZone($timezone) is called, it is checked whether the time zone passed is contained in the list of valid time zones (\DateTimeZone::listIdentifiers()). If not, the time zone is set to 'UTC' to ensure that no error occurs.
It is now ensured that no infinite loop is created in the callback function for preg_replace_callback() and that invalid or unhandled format characters are properly intercepted.
If no timestamp (0, null invalid) is passed to the date_strformat function, the timestamp is determined using the date_time function.
In the theme_smarty_modifier_date_rfc3339 function (RSS/Atom feed), date, time with time offset is now used.
Improvements:
The strftime_replacement function now correctly throws objects of type Exception Error.
The combination of format, time zone and locale is now cached to reduce IntlDateFormatter objects and save memory. Before
new \DateTimeZone($timezone)
is called, it is checked whether the time zone passed is contained in the list of valid time zones (\DateTimeZone::listIdentifiers()
). If not, the time zone is set to 'UTC' to ensure that no error occurs.It is now ensured that no infinite loop is created in the callback function for
preg_replace_callback()
and that invalid or unhandled format characters are properly intercepted.If no timestamp (0, null invalid) is passed to the
date_strformat
function, the timestamp is determined using thedate_time function
.In the
theme_smarty_modifier_date_rfc3339
function (RSS/Atom feed), date, time with time offset is now used.