#25051: now template tag documentation
--------------------------------------+--------------------
Reporter: marktranchant | Owner: nobody
Type: Cleanup/optimization | Status: new
Component: Documentation | Version: master
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 1 | UI/UX: 0
--------------------------------------+--------------------
The documentation
[https://docs.djangoproject.com/en/1.8/ref/templates/builtins/#now here]
says:
You can also use the syntax {{{ {% now "Y" as current_year %} }}} to
store the output inside a variable.
I think it'd be worth clarifying that {{{ current_year }}} will then be a
string not an integer. I spent a while working out why {{{ {% if
current_year > 2015 %} }}} was returning {{{True}}}.
--
Ticket URL: <https://code.djangoproject.com/ticket/25051>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/056.c25deba55b815a37f3e977841ecd06f6%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.