appendix C Django template tag and filter reference

This appendix is a reference guide for the built-in tags and filters available in the Django template language. For a full reference, see the online documentation: https://docs.djangoproject.com/en/dev/ref/templates/builtins/.

C.1 Tags

Table C.1 Built-in Django template tags
Tag
Description
{% autoescape off %}
    {{ venue_listing }}
{% endautoescape %}
By default, Django escapes characters in variables that are reserved for HTML. The {% autoescape %} tag allows you to control this behavior by turning it on or off for a block. In this example, if {{ venue_listing }} contained HTML tags, they could be rendered without being escaped inside {% autoescape off %}. {% autoescape ...

Get Django in Action now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.