summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorAdrian Holovaty <adrian@holovaty.com>2007-02-12 17:13:08 +0000
committerAdrian Holovaty <adrian@holovaty.com>2007-02-12 17:13:08 +0000
commitb9677848f5ae707e52ce96c067878707015c45cd (patch)
tree1746ccfdccb7829ac37c16c576db51ac8e442f73 /docs
parent38f9d8dac66cead8dffe18eb4f4a7db6ceff105b (diff)
Small formatting tweaks to named-end-blocks change from [4489]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4492 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs')
-rw-r--r--docs/templates.txt13
1 files changed, 9 insertions, 4 deletions
diff --git a/docs/templates.txt b/docs/templates.txt
index 9b3825f9f7..651866e52e 100644
--- a/docs/templates.txt
+++ b/docs/templates.txt
@@ -253,10 +253,15 @@ Here are some tips for working with inheritance:
if you want to add to the contents of a parent block instead of
completely overriding it.
- * You can optionally name your ``{{ endblock }}`` tag with the same name
- you gave the ``{{ block }}`` tag (for example, ``{{ endblock content }}``).
- In larger templates this helps you see which ``{{ block }}`` tags are
- being closed.
+ * **New in Django development version:** For extra readability, you can
+ optionally give a *name* to your ``{% endblock %}`` tag. For example::
+
+ {% block content %}
+ ...
+ {% endblock content %}
+
+ In larger templates, this technique helps you see which ``{% block %}``
+ tags are being closed.
Finally, note that you can't define multiple ``{% block %}`` tags with the same
name in the same template. This limitation exists because a block tag works in