Re: User object available in base template

2006-10-04 Thread Patrick J. Anderson
Don Arbow wrote: > On Oct 3, 2006, at 9:30 PM, Patrick J. Anderson wrote: >> def main(request): >> posts = Post.objects.filter(is_approved = >> True).order_by('-time_added')[:5] >> t = loader.get_template('homepage.html') >> c = RequestContext({ >> 'latest_posts': posts, >>

Re: User object available in base template

2006-10-03 Thread Alan Green
On 10/4/06, Patrick J. Anderson <[EMAIL PROTECTED]> wrote: ... > def main(request): > posts = Post.objects.filter(is_approved = > True).order_by('-time_added')[:5] > t = loader.get_template('homepage.html') > c = RequestContext({ > 'latest_posts': posts, > }) That's

Re: User object available in base template

2006-10-03 Thread Don Arbow
On Oct 3, 2006, at 9:30 PM, Patrick J. Anderson wrote: > > def main(request): > posts = Post.objects.filter(is_approved = > True).order_by('-time_added')[:5] > t = loader.get_template('homepage.html') > c = RequestContext({ > 'latest_posts': posts, > }) > return H

Re: User object available in base template

2006-10-03 Thread Patrick J. Anderson
Forgot to add my specific error: Exception Type: AttributeError Exception Value:'dict' object has no attribute 'user' Exception Location: /usr/lib/python2.4/site-packages/django/core/context_processors.py in auth, line 17 Patrick J. Anderson Patrick J. Anderson wrote: > In m

User object available in base template

2006-10-03 Thread Patrick J. Anderson
In my project, I have a root template called base.html, which all other templates extend. I'd like to create a simple navigation with user information, which I want to write once and put in the base template to be shown on every page. I'm not sure what the best way of retrieving information fr