projects
/
web/konrad/twig.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
e142fca
)
fixed a typo in the docs (closes #1136)
author
Fabien Potencier
<fabien.potencier@gmail.com>
Sat, 13 Jul 2013 19:17:34 +0000 (21:17 +0200)
committer
Fabien Potencier
<fabien.potencier@gmail.com>
Sat, 13 Jul 2013 19:17:34 +0000 (21:17 +0200)
doc/functions/date.rst
patch
|
blob
|
history
diff --git
a/doc/functions/date.rst
b/doc/functions/date.rst
index
fd67fc5
..
f1c9481
100644
(file)
--- a/
doc/functions/date.rst
+++ b/
doc/functions/date.rst
@@
-11,7
+11,7
@@
Converts an argument to a date to allow date comparison:
.. code-block:: jinja
- {% if date(user.created_at) < date('+2days') %}
+ {% if date(user.created_at) < date('-2days') %}
{# do something #}
{% endif %}
@@
-21,7
+21,7
@@
You can pass a timezone as the second argument:
.. code-block:: jinja
- {% if date(user.created_at) < date('+2days', 'Europe/Paris') %}
+ {% if date(user.created_at) < date('-2days', 'Europe/Paris') %}
{# do something #}
{% endif %}