#5756: Any template tag that uses resolve_variable instead of
parser.compile_filter does not handle filters.
-----------------------+----------------------------------------------------
Reporter: sneeu | Owner: nobody
Status: new | Component: Template system
Version: SVN | Keywords: ifequal variable filter template tag
Stage: Unreviewed | Has_patch: 0
-----------------------+----------------------------------------------------
On a page with the URL '/account/login/', I would expect the following to
work:
{{{
{% ifequal request.path|slice:"9" "/account/" %}Do something for account
pages.{% endifequal %}
}}}
As I understand it the underlying code (for ifequal and other template
tag) uses resolve_variable so the first argument becomes:
{{{
request.get('path|slice:":9"')
}}}
Currently a workaround using the 'with' template tag is required:
{{{
{% with request.path|slice:"9" as path_prefix %}Do something ...{% endwith
%}
}}}
--
Ticket URL: <http://code.djangoproject.com/ticket/5756>
Django Code <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---