fromdjango.http.response importHttpResponse
fromdjango.shortcuts importrender, render_to_response
# Create your views here.
defIndex(request):
returnHttpResponse('hello world')
defAuth(request):
printrequest.GET
user,password =request.GET['userName'],request.GET['password']
ifuser =='Jerome'andpassword =='123123':
returnHttpResponse('welcome user: %s'%user)
else:
returnHttpResponse('wrong userName or password')
returnHttpResponse('data submitted')
defLogin(request):
returnrender_to_response('index.html')