#NEWLINE# def login( request ) : #NEWLINE# #INDENT# if ( request . method == 'POST' ) : #NEWLINE# #INDENT# form = LoginForm ( request . POST ) #NEWLINE# if form . is_valid ( ) : #NEWLINE# #INDENT# request . session [ 'login' ] = form . cleaned_data [ 'login' ] #NEWLINE# return HttpResponseRedirect ( reverse ( 'registration.views.login.success' ) ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# form = LoginForm ( ) #NEWLINE# #UNINDENT# return render_to_response ( 'login/login.html' , { #NEWLINE# #INDENT# 'form' : form , #NEWLINE# #UNINDENT# } )