>
> I have total newbie question.
>
> I am following the Django tutorial under a Pinax install. Everything
> seems to be working correctly except a problem with templates. The
> home page looks fine, but when I click on a link driven by an
> application's template (such as the poll_list.html template from the
> tutorial) I get the plain black text on a plain white page (i.e. I get
> the list of polls without any of the base site or base template
> information such as logos, headers, and tabs). I've tried extending
> from the site_base template by adding "{% extends "site_base.html" %}"
> and putting the template code in a "{% block body %}" block, but the
> header and everything else are still broken. For example, there is an
> image box for logo.png but it can't find the .png file, and I get
> "login" and "signup" links (that work) but they're on a plain white
> background.
The problem you describe sounds like you haven't used RequestContext in your
view when rendering the template. This is critical and every view should
normally use this. There are some rare cases a view which handles an
HttpRequest will not need them.
Part four [1] of the tutorial seems to first show the use of a RequestContext
likely doing so for CSRF tokens. Make sure you copy how it is done to get
the media to load correctly on the page.
[1]: http://docs.djangoproject.com/en/1.2/intro/tutorial04/#intro-tutorial04
Brian Rosner
http://oebfare.com
http://twitter.com/brosner