List all form related errors in django
Posted
by Mridang Agarwalla
on Stack Overflow
See other posts from Stack Overflow
or by Mridang Agarwalla
Published on 2010-06-11T21:16:20Z
Indexed on
2010/06/11
21:22 UTC
Read the original article
Hit count: 268
Hi,
Is there a direct way of listing out 'all' form errors in Django templates. I'd like to list out both field and non-field errors and any other form errors.
I've found out how to do this on a per-field basis but as said earlier, I'd like to list out everything.
The method I'm using doesn't seem to list out everything.
{% for error in form.errors %}
{{ error|escape }}
{% endfor %}
Thanks.
© Stack Overflow or respective owner