I'm going through the tutorial, about views right now. I have this
code:

def index(request):
    latest_poll_list = Poll.objects.all().order_by('-pub_date')[:5]
    t = loader.get_template('polls/index.html')
    c = Context({
        'latest_poll_list': latest_poll_list
    })
    HttpResponse(t.render(c))

But it's saying that it didn't return an HttpResponse object when I go
to the page. I tried everything I could think of, but it won't work.
Am I doing something wrong?


Sorry if this has been asked before, but I didn't see anything quite
like it in my searching.

-- 
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.

Reply via email to