Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from django.contrib import messages
- from django.contrib.auth.models import User
- from django.shortcuts import render_to_response, RequestContext, Http404, HttpResponseRedirect
- from .models import Question, Answer, UserAnswer
- def all_questions(request):
- questions = Question.objects.all()
- if request.method == 'POST':
- print request.POST['question_id']
- print request.POST['answer']
- return render_to_response('questions/all.html', locals(), context_instance=RequestContext(request))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement