From 10a39debb2b95b41c8c4ec53247a3d1efe6c7f1b Mon Sep 17 00:00:00 2001 From: Vajrasky Kok Date: Sat, 9 Nov 2013 18:27:37 +0800 Subject: [PATCH] Fixed #21378 -- Updated tutorial02 for how to override admin site header. --- docs/intro/tutorial02.txt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/docs/intro/tutorial02.txt b/docs/intro/tutorial02.txt index 6d0d50ed27..74a6752188 100644 --- a/docs/intro/tutorial02.txt +++ b/docs/intro/tutorial02.txt @@ -475,8 +475,11 @@ template directory in the source code of Django itself import django print(django.__path__)" -Then, just edit the file and replace the generic Django text with your own -site's name as you see fit. +Then, just edit the file and replace ``{{ site_header }}`` with your own +site's name as you see fit. We use this approach to teach you how to override +templates. In an actual project, you would probably use the +:attr:`django.contrib.admin.AdminSite.site_header` attribute to more easily +make this paritcular customization. This template file contains lots of text like ``{% block branding %}`` and ``{{ title }}``. The ``{%`` and ``{{`` tags are part of Django's