Skip to content

Commit

Permalink
[1.1.X] Fixed #6752 -- Corrected the interaction of the safe template…
Browse files Browse the repository at this point in the history
… filter with other filters. Thanks to Rupe and Alex Gaynor for their work on the patch.

Backport of r13171 from trunk.

git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.1.X@13177 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
freakboy3742 committed May 9, 2010
1 parent 2ee73c2 commit c772e39
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions docs/ref/templates/builtins.txt
Expand Up @@ -1477,6 +1477,16 @@ safe
Marks a string as not requiring further HTML escaping prior to output. When
autoescaping is off, this filter has no effect.

.. note::

If you are chaining filters, a filter applied after ``safe`` can
make the contents unsafe again. For example, the following code
prints the variable as is, unescaped:

.. code-block:: html+django

{{ var|safe|escape }}

.. templatefilter:: safeseq

safeseq
Expand Down

0 comments on commit c772e39

Please sign in to comment.