Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed some more formatting bugs in [625]

git-svn-id: http://code.djangoproject.com/svn/django/trunk@627 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 276731d625f15ba8a1bb4abd30d64bff10f6b9eb 1 parent adae680
@adrianholovaty adrianholovaty authored
Showing with 9 additions and 6 deletions.
  1. +9 −6 docs/templates_python.txt
View
15 docs/templates_python.txt
@@ -436,9 +436,12 @@ available to Django's template language::
``register_filter`` takes three arguments:
- 1. The name of the filter -- a string
- 2. The Python function
- 3. A boolean, designating whether the filter requires an argument
+ 1. The name of the filter -- a string.
+ 2. The compilation function -- a Python function (not the name of the
+ function as a string).
+ 3. A boolean, designating whether the filter requires an argument. This
+ tells Django's template parser whether to throw ``TemplateSyntaxError``
+ when filter arguments are given (or missing).
The convention is to put all ``register_filter`` calls at the bottom of your
template-library module.
@@ -563,9 +566,9 @@ Finally, use a ``register_tag`` call, as in ``register_filter`` above. Example::
``register_tag`` takes two arguments:
- * The name of the template tag -- a string
- * The compilation function -- a Python function (not the name of the
- function as a string)
+ 1. The name of the template tag -- a string
+ 2. The compilation function -- a Python function (not the name of the
+ function as a string)
Setting a variable in the context
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Please sign in to comment.
Something went wrong with that request. Please try again.