I have tried to implement redirect
in django 4.1.1 views. Please find the following code.
redirect is working
def customer_registration(request):
return redirect('customer_login')
redirect not working
def customer_registration(request):
print("ASFADFAd")
if request.method == 'POST':
return redirect('customer_login')
return render(request, 'registration/registration.html')
Can anyone help what is the problem, I have already gone through the internet none of the solutions working. Please help me.