Invalid filter: 'unlocalize' (Django 3.1.7, Python 3.7.3)

350 views
Skip to first unread message

Jaap van Wingerde

unread,
Mar 19, 2021, 5:57:17 PM3/19/21
to django...@googlegroups.com
I try to use the filter 'localize'
<https://docs.djangoproject.com/en/3.1/topics/i18n/formatting/#std:templatefilter-localize>
in a template.

Django says 'TemplateSyntaxError':
TemplateSyntaxError at /beelden-en-glas/zomergeluid/
Invalid filter: 'unlocalize'
Request Method: GET
Request URL:
https://glaskunst-3.liakoster.nl/beelden-en-glas/zomergeluid/?beelden-en-glas-te-koop
Django Version: 3.1.7 Exception Type:
TemplateSyntaxError Exception Value:
Invalid filter: 'unlocalize'
Exception
Location: /var/django/liakoster.nl/glaskunst-3/lib/python3.7/site-packages/django/template/base.py,
line 569, in find_filter Python Executable: /usr/bin/python3
Python Version: 3.7.3
...
Error during template rendering

In
template /var/django/liakoster.nl/glaskunst-3/art/templates/art_artobject.json-ld,
error at line 30 Invalid filter: 'unlocalize'
...
30 "price": "{{ art_artobject.price|unlocalize }}", "priceCurrency":
"EUR",{% endif %}
...

Am I doing something wrong?

--

Jaap van Wingerde
e-mail: ja...@vanwingerde.nl

Reply all
Reply to author
Forward
0 new messages