I am really struggling to understand the following:
The Database runs in UTC. The user’s TimeZone is CET. And I want to take the UTC datetime from the database, convert it to CET and show it.
I want to load a date that is stored as ‘2019-12-14 08:32:17’ in the database as UTC. Now I want to convert it to CET. But if I do that, it looks like Twig assumes the date is already CET and changes nothing. How do I make twig load the date as UTC so that the filter …|date(“d.m.Y H:i”, “Europe/Berlin”) has an effect?
Here’s some examples what my outputs in twig are:
Source: Symfony Questions