On Sep 3, 1:00 am, Alex Koshelev <[EMAIL PROTECTED]> wrote: > Please show your views code or tell what you pass into template > context.
Sure thing, here's my views code for the events app. from mysite.events.models import Event from django.shortcuts import render_to_response, get_object_or_404 from django.http import HttpResponseRedirect def list_events(request): latest_event_list = Event.objects.all() return render_to_response('events/index.html', {'latest_event_list': latest_event_list}) And here's the views code the polls app. from mysite.polls.models import Poll from django.shortcuts import render_to_response, get_object_or_404 from django.http import HttpResponseRedirect def index(request): latest_poll_list = Poll.objects.all().order_by('-pub_date')[:5] return render_to_response('polls/index.html', {'latest_poll_list': latest_poll_list}) --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---