diff options
| author | Nick Presta <nick@nickpresta.ca> | 2014-04-14 23:58:51 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-06-02 15:22:15 -0400 |
| commit | 11f0899bbe7c04dc6109f57c3b36ed8621b8f08e (patch) | |
| tree | 92bbc93a67159d5c418ae128598de4b6db326b52 /docs/topics/forms | |
| parent | a00efa30d6e5ca220b914415904fff5fa0a6f2c5 (diff) | |
Fixed #11776 -- Added CSS class for non-field/top of form errors.
Thanks Daniel Pope for the suggestion.
Diffstat (limited to 'docs/topics/forms')
| -rw-r--r-- | docs/topics/forms/index.txt | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/topics/forms/index.txt b/docs/topics/forms/index.txt index f3afac5ab9..8db24f68d0 100644 --- a/docs/topics/forms/index.txt +++ b/docs/topics/forms/index.txt @@ -292,6 +292,17 @@ over them:: </ol> {% endif %} +.. versionchanged:: 1.8 + +Non-field errors (and/or hidden field errors that are rendered at the top of +the form when using helpers like ``form.as_p()``) will be rendered with an +additional class of ``nonfield`` to help distinguish them from field-specific +errors. For example, ``{{ form.non_field_errors }}`` would look like:: + + <ul class="errorlist nonfield"> + <li>Generic validation error</li> + </ul> + Looping over the form's fields ------------------------------ |
