Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #4000 - changed documentation to note that filter arguments no …

…longer need to be quoted (and added a test to that effect). Thanks, SmileyChris.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@5436 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit f6491bf98402a8896ee1d3f5c7912e588b57a7b8 1 parent 908b72f
@jacobian jacobian authored
Showing with 6 additions and 3 deletions.
  1. +6 −3 docs/templates.txt
View
9 docs/templates.txt
@@ -91,9 +91,12 @@ Filters can be "chained." The output of one filter is applied to the next.
``{{ text|escape|linebreaks }}`` is a common idiom for escaping text contents,
then converting line breaks to ``<p>`` tags.
-Some filters take arguments. A filter argument looks like this:
-``{{ bio|truncatewords:"30" }}``. This will display the first 30 words of the
-``bio`` variable. Filter arguments always are in double quotes.
+Some filters take arguments. A filter argument looks like this: ``{{
+bio|truncatewords:30 }}``. This will display the first 30 words of the ``bio``
+variable.
+
+Filter arguments that contain spaces must be quoted; for example, to join a list
+with commas and spaced you'd use ``{{ list|join:", " }}``.
The `Built-in filter reference`_ below describes all the built-in filters.
Please sign in to comment.
Something went wrong with that request. Please try again.