From: Matthijs Kooijman Date: Tue, 19 Oct 2010 08:51:50 +0000 (+0200) Subject: tickets: Use RequestContext. X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;h=b0dc7832eac85f62c17de630b0dd5b3817db74ff;p=matthijs%2Fprojects%2Fdorestad-bookings.git tickets: Use RequestContext. --- diff --git a/tickets/views.py b/tickets/views.py index 3e9547f..f0cdfa4 100644 --- a/tickets/views.py +++ b/tickets/views.py @@ -2,6 +2,7 @@ import django from django.shortcuts import render_to_response +from django.template import RequestContext from models import Booking @@ -57,6 +58,6 @@ def book(request): if f.is_valid(): booking = f.save() confirm_booking(booking) - return render_to_response('tickets/booked.html', {'booking' : booking}) + return render_to_response('tickets/booked.html', {'booking' : booking}, context_instance=RequestContext(request)) - return render_to_response('tickets/bookingform.html', {'form' : f}) + return render_to_response('tickets/bookingform.html', {'form' : f}, context_instance=RequestContext(request))