How to use the built-in 'password_reset' view in Django?

前端 未结 3 1417
别跟我提以往
别跟我提以往 2021-01-02 15:33

I have set the following entry in the urls.py

(r\'^password_reset/$\', \'django.contrib.auth.views.password_reset\'),

but once I go to

3条回答
  •  北海茫月
    2021-01-02 16:00

    Django needs to know which URL to redirect the user to once they have completed the form on the password_reset page. So add another line to your URL configuration:

    (r'^password_reset_done/$', 'django.contrib.auth.views.password_reset_done'),
    

提交回复
热议问题