diff options
| author | Jacob Kaplan-Moss <jacob@jacobian.org> | 2007-06-07 18:18:44 +0000 |
|---|---|---|
| committer | Jacob Kaplan-Moss <jacob@jacobian.org> | 2007-06-07 18:18:44 +0000 |
| commit | f6491bf98402a8896ee1d3f5c7912e588b57a7b8 (patch) | |
| tree | cffbfd006f28366a88e43cf0020be6faa78d909d /docs | |
| parent | 908b72f76d9f4d4a9555f39669a95f3bdb0764c0 (diff) | |
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
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/templates.txt | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/docs/templates.txt b/docs/templates.txt index a293bdcff2..d8b511dedc 100644 --- a/docs/templates.txt +++ b/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. |
