admin templates problem

2009-03-01 Thread knight

Hi,

I have a django application where I override the main admin page
(index.html in template/admin)
I use apache, I have a link to admin media folder and I have a
following problem:

In my admin pages I see the admin templates on all the pages except
the one I overrided (index.html).
Is anyone know what can be the problem?

Thanks, Arshavski Alexander.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---



Re: admin templates problem

2009-03-01 Thread Malcolm Tredinnick

On Sun, 2009-03-01 at 21:06 -0800, knight wrote:
> Hi,
> 
> I have a django application where I override the main admin page
> (index.html in template/admin)
> I use apache, I have a link to admin media folder and I have a
> following problem:
> 
> In my admin pages I see the admin templates on all the pages except
> the one I overrided (index.html).

What do you mean when you say you don't see the admin template? Do you
not see your custom version? Or you don't see anything?

Regards,
Malcolm



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---



Re: admin templates problem

2009-03-01 Thread Alex Gaynor
On Mon, Mar 2, 2009 at 12:39 AM, Malcolm Tredinnick <
malc...@pointy-stick.com> wrote:

>
> On Sun, 2009-03-01 at 21:06 -0800, knight wrote:
> > Hi,
> >
> > I have a django application where I override the main admin page
> > (index.html in template/admin)
> > I use apache, I have a link to admin media folder and I have a
> > following problem:
> >
> > In my admin pages I see the admin templates on all the pages except
> > the one I overrided (index.html).
>
> What do you mean when you say you don't see the admin template? Do you
> not see your custom version? Or you don't see anything?
>
> Regards,
> Malcolm
>
>
>
> >
> The index.html is only for the index page, perhaps you meant to overide
base.html or base_site.html?

Alex


-- 
"I disapprove of what you say, but I will defend to the death your right to
say it." --Voltaire
"The people's good is the highest law."--Cicero

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---



Re: admin templates problem

2009-03-01 Thread alexarsh

I can't see the blue admin template. I can't see it only on the page I
overrided - (contrib/admin/templates/admin/index.html)

Regards, Alex A.

On Mar 2, 7:39 am, Malcolm Tredinnick 
wrote:
> On Sun, 2009-03-01 at 21:06 -0800, knight wrote:
> > Hi,
>
> > I have a django application where I override the main admin page
> > (index.html in template/admin)
> > I use apache, I have a link to admin media folder and I have a
> > following problem:
>
> > In my admin pages I see the admin templates on all the pages except
> > the one I overrided (index.html).
>
> What do you mean when you say you don't see the admin template? Do you
> not see your custom version? Or you don't see anything?
>
> Regards,
> Malcolm
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---



Re: admin templates problem

2009-03-01 Thread Malcolm Tredinnick

On Sun, 2009-03-01 at 22:05 -0800, alexarsh wrote:
> I can't see the blue admin template. I can't see it only on the page I
> overrided - (contrib/admin/templates/admin/index.html)

Solving that will require seeing what your overridden template looks
like. I would guess that it might be something obvious like you forgot
to extend the base template. But it may be something else.

One easy way to debug this is to create a very simple override template
that changes nothing (so it only extends the base template). Check that
that displays identically to the normal admin. Then make a small change
-- perhaps overriding a single block. Check that that does what you
expect. Keep repeating in small steps.

At the moment, you've probably gone for a complete override template and
debugging is hard because you've changed a few dozen things all at once.
So go back to changing nothing except using an override. Then change one
more thing, then one more, and so on.

Regards,
Malcolm



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---



Re: admin templates problem

2009-03-01 Thread alexarsh

Thanks a lot. I found the problem. As you said, I missed one line.
I had:

{% block stylesheet %}{% load adminmedia %}{% admin_media_prefix %}css/
dashboard.css{% endblock %}

instead of:

{% block extrastyle %}{%
endblock %}

Thanks,
Alex A.

On Mar 2, 8:19 am, Malcolm Tredinnick 
wrote:
> On Sun, 2009-03-01 at 22:05 -0800, alexarsh wrote:
> > I can't see the blue admin template. I can't see it only on the page I
> > overrided - (contrib/admin/templates/admin/index.html)
>
> Solving that will require seeing what your overridden template looks
> like. I would guess that it might be something obvious like you forgot
> to extend the base template. But it may be something else.
>
> One easy way to debug this is to create a very simple override template
> that changes nothing (so it only extends the base template). Check that
> that displays identically to the normal admin. Then make a small change
> -- perhaps overriding a single block. Check that that does what you
> expect. Keep repeating in small steps.
>
> At the moment, you've probably gone for a complete override template and
> debugging is hard because you've changed a few dozen things all at once.
> So go back to changing nothing except using an override. Then change one
> more thing, then one more, and so on.
>
> Regards,
> Malcolm
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@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
-~--~~~~--~~--~--~---