I am using Django built in view for user login:
url(r\'^user/login/$\', \'django.contrib.auth.views.login\', {\'template_name\': \'users/templates/login.html\'},
Two ways, either you can use logout "LOGIN_REDIRECT_URL" or
just use the url which redirects to the view method which has @login_required decorator
example
for second login , after logout (below code is in logout.html)
Login again
In views.py
@login_required
def home(request):
return HttpResponse("Welcome")