diff options
| author | Curtis Maloney <curtis@tinbrain.net> | 2013-08-28 22:17:20 +1000 |
|---|---|---|
| committer | Anssi Kääriäinen <akaariai@gmail.com> | 2013-08-29 10:22:24 +0300 |
| commit | 5cdacbda034af928f5033c9afc7b50ee0b13f75c (patch) | |
| tree | 5621b597d673fffbcca6c70fbdd3f132ec1b1f31 /docs/ref | |
| parent | 169637649baa012a8a77b17465c5c0c1085336ea (diff) | |
Fixed #17356 -- Allowed {% include %} to render compiled templates
Reviewed by Loic Bistuer and Tim Graham.
Diffstat (limited to 'docs/ref')
| -rw-r--r-- | docs/ref/templates/builtins.txt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt index 5b02ab22d1..767906cd8b 100644 --- a/docs/ref/templates/builtins.txt +++ b/docs/ref/templates/builtins.txt @@ -691,6 +691,12 @@ the variable ``template_name``:: {% include template_name %} +.. versionchanged:: 1.7 + + The variable may also be any object with a ``render()`` method that + accepts a context. This allows you to reference a compiled ``Template`` in + your context. + An included template is rendered with the context of the template that's including it. This example produces the output ``"Hello, John"``: |
