Date helper returns wrong time if date() function is used

Notice: This thread is very old.
Generous Backer | 236

I have a template with this:

{date('d', 1408226400)}
{strftime('%d', 1408226400)}

It should render four equal numbers. But it renders 17 17 17 16

There is some problem width date helper, probably something with timezone.

Nette 2.2

In config.neon:

	date.timezone: Europe/Prague

Can you help me find where is the problem?

Jan Tvrdík
Nette guru | 2573

It's a bug in Nette 2.2, I'm going to send a fix now.


Last edited by Jan Tvrdík (2014-08-17 16:15)