It's useful to have some templates with the same name of another one,
like you can do with YOURPROJECT/templates/admin/base_site.html that
override the base site django default.
but If I want to add a word in the title of my base_site.html I need
to copy the entire content of the base_site.html I am overriding, and
I cannot extend it to avoid that with am {% extend
"admin/templates/base_site.html" %}
or an {% extend super %}

I wrote a custom base_site.html with some common code for all my projects.
Now I need an app to add a single template_tag in a block. Is it
possible without copying ALL the previous base_site?
I cannot change the name of the parent template, or admin will not use
it when I don't install that app.

I moved
YOURPROJECT/templates/admin/base_site.html
to
YOURPROJECT/templates/admin/_base_site.html

and created an empty
YOURPROJECT/templates/admin/base_site.html
with only
{% extends "_base_site.html" %}

but it's not clean.

Is there any other cleaner way to do that?

-- 
Alessandro Ronchi
http://www.soasi.com

Hobby & Giochi
http://hobbygiochi.com
http://www.facebook.com/hobbygiochi

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to