Browse files

[1.2.X] Fixed #13350 - Documentation on autoescape should mention end…


Thanks to for report and to dwillis for patch.

Backport of [13694] from trunk

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
spookylukey committed Sep 7, 2010
1 parent 79d9206 commit 1b910d7fbcc664ae22bef010af05746027b82138
Showing with 7 additions and 1 deletion.
  1. +7 −1 docs/ref/templates/builtins.txt
@@ -23,7 +23,7 @@ autoescape
Control the current auto-escaping behavior. This tag takes either ``on`` or
``off`` as an argument and that determines whether auto-escaping is in effect
-inside the block.
+inside the block. The block is closed with an ``endautoescape`` ending tag.
When auto-escaping is in effect, all variable content has HTML escaping applied
to it before placing the result into the output (but after any filters have
@@ -34,6 +34,12 @@ The only exceptions are variables that are already marked as "safe" from
escaping, either by the code that populated the variable, or because it has had
the ``safe`` or ``escape`` filters applied.
+Sample usage::
+ {% autoescape on %}
+ {{ body }}
+ {% endautoescape %}
.. templatetag:: block

0 comments on commit 1b910d7

Please sign in to comment.