{"id":6126,"date":"2022-12-04T08:58:28","date_gmt":"2022-12-04T08:58:28","guid":{"rendered":"https:\/\/www.pythontutorial.net\/?page_id=6126"},"modified":"2023-08-17T09:53:17","modified_gmt":"2023-08-17T09:53:17","slug":"django-password-reset","status":"publish","type":"page","link":"https:\/\/www.pythontutorial.net\/django-tutorial\/django-password-reset\/","title":{"rendered":"Django Password Reset"},"content":{"rendered":"\n<p><strong>Summary<\/strong>: in this tutorial, you&#8217;ll learn how to implement the Django Password Reset feature that allows users to reset their passwords using email addresses.<\/p>\n\n\n\n<p class=\"note\">This tutorial begins where&nbsp;the&nbsp;<a href=\"https:\/\/www.pythontutorial.net\/django-tutorial\/django-formview\/\">Django FormView tutorial<\/a>&nbsp;left off.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id='introduction-to-the-password-reset-in-django'>Introduction to the password reset in Django <a href=\"#introduction-to-the-password-reset-in-django\" class=\"anchor\" id=\"introduction-to-the-password-reset-in-django\" title=\"Anchor for Introduction to the password reset in Django\">#<\/a><\/h2>\n\n\n\n<p>The following diagram illustrates the flow that allows a user to reset the password using an email address:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"629\" height=\"545\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/Django-Password-Reset.png\" alt=\"\" class=\"wp-image-6146\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/Django-Password-Reset.png 629w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/Django-Password-Reset-300x260.png 300w\" sizes=\"auto, (max-width: 629px) 100vw, 629px\" \/><\/figure>\n\n\n\n<p>First, the user clicks the Reset Password link on the login form: <\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"645\" height=\"612\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-loginform-1.png\" alt=\"\" class=\"wp-image-6138\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-loginform-1.png 645w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-loginform-1-300x285.png 300w\" sizes=\"auto, (max-width: 645px) 100vw, 645px\" \/><\/figure>\n\n\n\n<p>Django displays a form that allows the user to enter an email address for receiving the password reset link:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"629\" height=\"349\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password.png\" alt=\"\" class=\"wp-image-6139\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password.png 629w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-300x166.png 300w\" sizes=\"auto, (max-width: 629px) 100vw, 629px\" \/><\/figure>\n\n\n\n<p>Django uses the <code>PasswordResetView<\/code> view to render this form.<\/p>\n\n\n\n<p>Second, the user enters an email address and clicks the Send button:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"632\" height=\"347\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-form.png\" alt=\"\" class=\"wp-image-6130\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-form.png 632w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-form-300x165.png 300w\" sizes=\"auto, (max-width: 632px) 100vw, 632px\" \/><\/figure>\n\n\n\n<p>Django sends an email to the input email address and displays a message that instructs the user to check the inbox.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"737\" height=\"181\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-done.png\" alt=\"\" class=\"wp-image-6137\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-done.png 737w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-reset-password-done-300x74.png 300w\" sizes=\"auto, (max-width: 737px) 100vw, 737px\" \/><\/figure>\n\n\n\n<p>Django uses the <code>PasswordResetDoneView<\/code> class to render this form.<\/p>\n\n\n\n<p>Third, the user opens the inbox and clicks the password reset link:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"834\" height=\"281\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-email.png\" alt=\"\" class=\"wp-image-6131\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-email.png 834w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-email-300x101.png 300w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-email-768x259.png 768w\" sizes=\"auto, (max-width: 834px) 100vw, 834px\" \/><\/figure>\n\n\n\n<p>Finally, the user enters the new password and clicks the Reset Password button:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"643\" height=\"466\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-password-reset-confirm.png\" alt=\"\" class=\"wp-image-6132\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-password-reset-confirm.png 643w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-password-reset-confirm-300x217.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><figcaption class=\"wp-element-caption\"><br><\/figcaption><\/figure>\n\n\n\n<p>Django displays a confirmation message:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"616\" height=\"114\" src=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-completed.png\" alt=\"\" class=\"wp-image-6133\" srcset=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-completed.png 616w, https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/django-password-reset-completed-300x56.png 300w\" sizes=\"auto, (max-width: 616px) 100vw, 616px\" \/><\/figure>\n\n\n\n<p>Django uses the <code>PasswordResetCompleteView<\/code> to handle this page.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id='implementing-password-reset-for-the-todo-app'>Implementing password reset for the Todo app <a href=\"#implementing-password-reset-for-the-todo-app\" class=\"anchor\" id=\"implementing-password-reset-for-the-todo-app\" title=\"Anchor for Implementing password reset for the Todo app\">#<\/a><\/h2>\n\n\n\n<p>Modify the <code>views.py<\/code> of the <code>users<\/code> application to map the password reset URL with the corresponding class-based views:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\"><span class=\"hljs-keyword\">from<\/span> django.urls <span class=\"hljs-keyword\">import<\/span> path\n<span class=\"hljs-keyword\">from<\/span> .views <span class=\"hljs-keyword\">import<\/span> MyLoginView, RegisterView\n\n<span class=\"hljs-keyword\">from<\/span> django.contrib.auth.views <span class=\"hljs-keyword\">import<\/span> (\n    LogoutView, \n    PasswordResetView, \n    PasswordResetDoneView, \n    PasswordResetConfirmView,\n    PasswordResetCompleteView\n)\n\nurlpatterns = &#91;\n    path(<span class=\"hljs-string\">'login\/'<\/span>, MyLoginView.as_view(redirect_authenticated_user=<span class=\"hljs-literal\">True<\/span>),name=<span class=\"hljs-string\">'login'<\/span>),\n    path(<span class=\"hljs-string\">'logout\/'<\/span>, LogoutView.as_view(next_page=<span class=\"hljs-string\">'login'<\/span>),name=<span class=\"hljs-string\">'logout'<\/span>),\n    path(<span class=\"hljs-string\">'register\/'<\/span>, RegisterView.as_view(),name=<span class=\"hljs-string\">'register'<\/span>),\n    path(<span class=\"hljs-string\">'password-reset\/'<\/span>, PasswordResetView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset.html'<\/span>),name=<span class=\"hljs-string\">'password-reset'<\/span>),\n    path(<span class=\"hljs-string\">'password-reset\/done\/'<\/span>, PasswordResetDoneView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset_done.html'<\/span>),name=<span class=\"hljs-string\">'password_reset_done'<\/span>),\n    path(<span class=\"hljs-string\">'password-reset-confirm\/&lt;uidb64&gt;\/&lt;token&gt;\/'<\/span>, PasswordResetConfirmView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset_confirm.html'<\/span>),name=<span class=\"hljs-string\">'password_reset_confirm'<\/span>),\n    path(<span class=\"hljs-string\">'password-reset-complete\/'<\/span>,PasswordResetCompleteView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset_complete.html'<\/span>),name=<span class=\"hljs-string\">'password_reset_complete'<\/span>),\n]<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h3 class=\"wp-block-heading\" id='passwordresetview'>PasswordResetView <a href=\"#passwordresetview\" class=\"anchor\" id=\"passwordresetview\" title=\"Anchor for PasswordResetView\">#<\/a><\/h3>\n\n\n\n<p>First, map the password reset URL <code>'password-reset\/'<\/code> with the result of the <code>as_view()<\/code> method of the <code><code>PasswordResetView<\/code><\/code> class. The <code><code>PasswordResetView<\/code><\/code> class-based view uses the <code>users\/password_reset.html<\/code> template to render the form.<\/p>\n\n\n\n<p>Second, create the <code>password_reset.html<\/code> template in the <code>templates\/users<\/code> directory:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-2\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">{%extends <span class=\"hljs-string\">'base.html'<\/span>%}\n\n{%block content%}\n&lt;div <span class=\"hljs-class\"><span class=\"hljs-keyword\">class<\/span>=\"<span class=\"hljs-title\">center<\/span>\"&gt;\n\t&lt;<span class=\"hljs-title\">form<\/span> <span class=\"hljs-title\">method<\/span>=\"<span class=\"hljs-title\">post<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">card<\/span>\"&gt;\n\t\t{% <span class=\"hljs-title\">csrf_token<\/span> %}\n\t    &lt;<span class=\"hljs-title\">h2<\/span> <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">text<\/span>-<span class=\"hljs-title\">center<\/span>\"&gt;<span class=\"hljs-title\">Reset<\/span> <span class=\"hljs-title\">Password<\/span>&lt;\/<span class=\"hljs-title\">h2<\/span>&gt;\n\t\t{% <span class=\"hljs-title\">for<\/span> <span class=\"hljs-title\">field<\/span> <span class=\"hljs-title\">in<\/span> <span class=\"hljs-title\">form<\/span> %}\n\t    \t\t{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">label_tag<\/span> }} \n\t        \t{{ <span class=\"hljs-title\">field<\/span> }}\n\t        \t{% <span class=\"hljs-title\">if<\/span> <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span> %}\n\t        \t\t&lt;<span class=\"hljs-title\">small<\/span>&gt;{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span>|<span class=\"hljs-title\">striptags<\/span>  }}&lt;\/<span class=\"hljs-title\">small<\/span>&gt; \n\t        \t{% <span class=\"hljs-title\">endif<\/span> %}\n\t\t{% <span class=\"hljs-title\">endfor<\/span> %}\n\t\t&lt;<span class=\"hljs-title\">div<\/span> <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">form<\/span>-<span class=\"hljs-title\">buttons<\/span>\"&gt;\n\t\t\t&lt;<span class=\"hljs-title\">input<\/span> <span class=\"hljs-title\">type<\/span>=\"<span class=\"hljs-title\">submit<\/span>\" <span class=\"hljs-title\">value<\/span>=\"<span class=\"hljs-title\">Send<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">btn<\/span> <span class=\"hljs-title\">btn<\/span>-<span class=\"hljs-title\">primary<\/span>\"&gt;\n\t\t\t&lt;<span class=\"hljs-title\">a<\/span> <span class=\"hljs-title\">href<\/span>=\"{%<span class=\"hljs-title\">url<\/span> '<span class=\"hljs-title\">login<\/span>' %}\"  <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">btn<\/span> <span class=\"hljs-title\">btn<\/span>-<span class=\"hljs-title\">outline<\/span>\"&gt;<span class=\"hljs-title\">Cancel<\/span>&lt;\/<span class=\"hljs-title\">a<\/span>&gt;\n\t\t&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n\t&lt;\/<span class=\"hljs-title\">form<\/span>&gt;\n\t&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n{%<span class=\"hljs-title\">endblock<\/span> <span class=\"hljs-title\">content<\/span>%}<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-2\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h3 class=\"wp-block-heading\" id='passwordresetdoneview'>PasswordResetDoneView <a href=\"#passwordresetdoneview\" class=\"anchor\" id=\"passwordresetdoneview\" title=\"Anchor for PasswordResetDoneView\">#<\/a><\/h3>\n\n\n\n<p>First, map the <code>password-reset\/done\/<\/code> with the result of the <code>as_view()<\/code> method of the <code><code>PasswordResetDoneView<\/code><\/code> class. The <code><code>PasswordResetDoneView<\/code><\/code> class uses the <code>password_reset_done.html<\/code> template to render the page:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-3\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">path(<span class=\"hljs-string\">'password-reset\/done\/'<\/span>, PasswordResetDoneView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset_done.html'<\/span>),name=<span class=\"hljs-string\">'password_reset_done'<\/span>),<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-3\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>Second, create the <code>reset_password_done.html<\/code> template in the <code>templates\/users<\/code> directory:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-4\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">{%extends <span class=\"hljs-string\">'base.html'<\/span>%}\n\n{%block content%}\n\n&lt;div <span class=\"hljs-class\"><span class=\"hljs-keyword\">class<\/span>=\"<span class=\"hljs-title\">center<\/span> <span class=\"hljs-title\">card<\/span>\"&gt;\n\t&lt;<span class=\"hljs-title\">h2<\/span>&gt;<span class=\"hljs-title\">Reset<\/span> <span class=\"hljs-title\">Password<\/span>&lt;\/<span class=\"hljs-title\">h2<\/span>&gt;\n\t&lt;<span class=\"hljs-title\">p<\/span>&gt;<span class=\"hljs-title\">Please<\/span> <span class=\"hljs-title\">check<\/span> <span class=\"hljs-title\">your<\/span> <span class=\"hljs-title\">inbox<\/span> <span class=\"hljs-title\">and<\/span> <span class=\"hljs-title\">follow<\/span> <span class=\"hljs-title\">the<\/span> <span class=\"hljs-title\">instruction<\/span> <span class=\"hljs-title\">to<\/span> <span class=\"hljs-title\">reset<\/span> <span class=\"hljs-title\">your<\/span> <span class=\"hljs-title\">password<\/span>.&lt;\/<span class=\"hljs-title\">p<\/span>&gt;\n&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n\n{%<span class=\"hljs-title\">endblock<\/span> <span class=\"hljs-title\">content<\/span>%}<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-4\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h3 class=\"wp-block-heading\" id='passwordresetconfirmview'>PasswordResetConfirmView <a href=\"#passwordresetconfirmview\" class=\"anchor\" id=\"passwordresetconfirmview\" title=\"Anchor for PasswordResetConfirmView\">#<\/a><\/h3>\n\n\n\n<p>First, map the <code>password-reset-confirm\/&lt;uidb64&gt;\/&lt;token&gt;\/<\/code> URL with the result of the <code>as_view()<\/code> of the <code>PasswordResetConfirmView<\/code> class:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-5\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">path(<span class=\"hljs-string\">'password-reset-confirm\/&lt;uidb64&gt;\/&lt;token&gt;\/'<\/span>, PasswordResetConfirmView.as_view(template_name=<span class=\"hljs-string\">'users\/password_reset_confirm.html'<\/span>),name=<span class=\"hljs-string\">'password_reset_confirm'<\/span>),<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-5\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>The <code>PasswordResetConfirmView<\/code> class uses the <code>password_reset_confirm.html<\/code> template to render the page. A reset password URL looks like this:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-6\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">http:\/\/<span class=\"hljs-number\">127.0<\/span><span class=\"hljs-number\">.0<\/span><span class=\"hljs-number\">.1<\/span>:<span class=\"hljs-number\">8000<\/span>\/password-reset-confirm\/OA\/bfwk0g-d87966e0a694f519bc6f29daa4616b07\/<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-6\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>Second, create the <code>password_reset_confirm.html<\/code> template in the <code>templates\/users<\/code> directory:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-7\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">{%extends <span class=\"hljs-string\">'base.html'<\/span>%}\n\n{%block content%}\n\n&lt;div <span class=\"hljs-class\"><span class=\"hljs-keyword\">class<\/span>=\"<span class=\"hljs-title\">center<\/span>\"&gt;\n\t&lt;<span class=\"hljs-title\">form<\/span> <span class=\"hljs-title\">method<\/span>=\"<span class=\"hljs-title\">post<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">card<\/span>\"&gt;\n\t  {% <span class=\"hljs-title\">csrf_token<\/span> %}\n\t  &lt;<span class=\"hljs-title\">h2<\/span>&gt;<span class=\"hljs-title\">Password<\/span> <span class=\"hljs-title\">Reset<\/span> <span class=\"hljs-title\">Confirm<\/span>&lt;\/<span class=\"hljs-title\">h2<\/span>&gt;\n\t  \n\t  {% <span class=\"hljs-title\">for<\/span> <span class=\"hljs-title\">field<\/span> <span class=\"hljs-title\">in<\/span> <span class=\"hljs-title\">form<\/span> %}\n\t    \t\t{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">label_tag<\/span> }} \n\t        \t{{ <span class=\"hljs-title\">field<\/span> }}\n\t        \t{% <span class=\"hljs-title\">if<\/span> <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span> %}\n\t        \t\t&lt;<span class=\"hljs-title\">small<\/span>&gt;{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span>|<span class=\"hljs-title\">striptags<\/span>  }}&lt;\/<span class=\"hljs-title\">small<\/span>&gt; \n\t        \t{% <span class=\"hljs-title\">endif<\/span> %}\n\t\t{% <span class=\"hljs-title\">endfor<\/span> %}\n\t  \n\t  \n\t  &lt;<span class=\"hljs-title\">div<\/span>&gt;\n\t    &lt;<span class=\"hljs-title\">button<\/span> <span class=\"hljs-title\">type<\/span>=\"<span class=\"hljs-title\">submit<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">btn<\/span> <span class=\"hljs-title\">btn<\/span>-<span class=\"hljs-title\">primary<\/span>\"&gt;<span class=\"hljs-title\">Reset<\/span> <span class=\"hljs-title\">Password<\/span>&lt;\/<span class=\"hljs-title\">button<\/span>&gt;\n\t  &lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n\t&lt;\/<span class=\"hljs-title\">form<\/span>&gt;\n&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n\n\n{%<span class=\"hljs-title\">endblock<\/span> <span class=\"hljs-title\">content<\/span>%}<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-7\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h3 class=\"wp-block-heading\" id='passwordresetcompleteview'>PasswordResetCompleteView <a href=\"#passwordresetcompleteview\" class=\"anchor\" id=\"passwordresetcompleteview\" title=\"Anchor for PasswordResetCompleteView\">#<\/a><\/h3>\n\n\n\n<p>First, map the password reset complete URL with the <code>as_view()<\/code> method of the <code>PasswordResetCompleteView<\/code> class.<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-8\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">{%extends <span class=\"hljs-string\">'base.html'<\/span>%}\n\n{%block content%}\n\n&lt;div <span class=\"hljs-class\"><span class=\"hljs-keyword\">class<\/span>=\"<span class=\"hljs-title\">card<\/span> <span class=\"hljs-title\">center<\/span>\"&gt;\n\t&lt;<span class=\"hljs-title\">p<\/span>&gt;<span class=\"hljs-title\">Your<\/span> <span class=\"hljs-title\">password<\/span> <span class=\"hljs-title\">has<\/span> <span class=\"hljs-title\">been<\/span> <span class=\"hljs-title\">changed<\/span> <span class=\"hljs-title\">successfully<\/span>. <span class=\"hljs-title\">Please<\/span> &lt;<span class=\"hljs-title\">a<\/span> <span class=\"hljs-title\">href<\/span>=\"{% <span class=\"hljs-title\">url<\/span> '<span class=\"hljs-title\">login<\/span>' %}\"&gt;<span class=\"hljs-title\">Login<\/span>&lt;\/<span class=\"hljs-title\">a<\/span>&gt;&lt;\/<span class=\"hljs-title\">p<\/span>&gt;\n&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n \t\n{%<span class=\"hljs-title\">endblock<\/span> <span class=\"hljs-title\">content<\/span>%}<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-8\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>Second, create the <code>password_reset_complete.html<\/code> template in the <code>templates\/users<\/code> directory<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-9\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">{%extends <span class=\"hljs-string\">'base.html'<\/span>%}\n\n{%block content%}\n  &lt;div <span class=\"hljs-class\"><span class=\"hljs-keyword\">class<\/span>=\"<span class=\"hljs-title\">center<\/span>\"&gt;\n\t  &lt;<span class=\"hljs-title\">form<\/span> <span class=\"hljs-title\">method<\/span>=\"<span class=\"hljs-title\">post<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">card<\/span>\" <span class=\"hljs-title\">novalidate<\/span>&gt;\n\t  \t{% <span class=\"hljs-title\">csrf_token<\/span> %}\n\t    &lt;<span class=\"hljs-title\">h2<\/span> <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">text<\/span>-<span class=\"hljs-title\">center<\/span>\"&gt;<span class=\"hljs-title\">Log<\/span> <span class=\"hljs-title\">in<\/span> <span class=\"hljs-title\">to<\/span> <span class=\"hljs-title\">your<\/span> <span class=\"hljs-title\">account<\/span>&lt;\/<span class=\"hljs-title\">h2<\/span>&gt;\n\t\t{% <span class=\"hljs-title\">for<\/span> <span class=\"hljs-title\">field<\/span> <span class=\"hljs-title\">in<\/span> <span class=\"hljs-title\">form<\/span> %}\n\t    \t\t{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">label_tag<\/span> }} \n\t        \t{{ <span class=\"hljs-title\">field<\/span> }}\n\t        \t{% <span class=\"hljs-title\">if<\/span> <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span> %}\n\t        \t\t&lt;<span class=\"hljs-title\">small<\/span>&gt;{{ <span class=\"hljs-title\">field<\/span>.<span class=\"hljs-title\">errors<\/span>|<span class=\"hljs-title\">striptags<\/span>  }}&lt;\/<span class=\"hljs-title\">small<\/span>&gt; \n\t        \t{% <span class=\"hljs-title\">endif<\/span> %}\n\t\t{% <span class=\"hljs-title\">endfor<\/span> %}\n\t\t\n\t\t&lt;<span class=\"hljs-title\">input<\/span> <span class=\"hljs-title\">type<\/span>=\"<span class=\"hljs-title\">submit<\/span>\" <span class=\"hljs-title\">value<\/span>=\"<span class=\"hljs-title\">Login<\/span>\" <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">btn<\/span> <span class=\"hljs-title\">btn<\/span>-<span class=\"hljs-title\">primary<\/span> <span class=\"hljs-title\">full<\/span>-<span class=\"hljs-title\">width<\/span>\"&gt;\n\t\t&lt;<span class=\"hljs-title\">hr<\/span>&gt;\n\t\t&lt;<span class=\"hljs-title\">p<\/span> <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">text<\/span>-<span class=\"hljs-title\">center<\/span>\"&gt;<span class=\"hljs-title\">Forgot<\/span> <span class=\"hljs-title\">your<\/span> <span class=\"hljs-title\">password<\/span> &lt;<span class=\"hljs-title\">a<\/span> <span class=\"hljs-title\">href<\/span>=\"{%<span class=\"hljs-title\">url<\/span> '<span class=\"hljs-title\">password<\/span>-<span class=\"hljs-title\">reset<\/span>'%}\"&gt;<span class=\"hljs-title\">Reset<\/span> <span class=\"hljs-title\">Password<\/span>&lt;\/<span class=\"hljs-title\">a<\/span>&gt;&lt;\/<span class=\"hljs-title\">p<\/span>&gt;\n\t\t&lt;<span class=\"hljs-title\">p<\/span> <span class=\"hljs-title\">class<\/span>=\"<span class=\"hljs-title\">text<\/span>-<span class=\"hljs-title\">center<\/span>\"&gt;<span class=\"hljs-title\">Don<\/span>'<span class=\"hljs-title\">t<\/span> <span class=\"hljs-title\">have<\/span> <span class=\"hljs-title\">a<\/span> <span class=\"hljs-title\">account<\/span>? &lt;<span class=\"hljs-title\">a<\/span> <span class=\"hljs-title\">href<\/span>=\"{%<span class=\"hljs-title\">url<\/span> '<span class=\"hljs-title\">register<\/span>'%}\"&gt;<span class=\"hljs-title\">Join<\/span> <span class=\"hljs-title\">Now<\/span>&lt;\/<span class=\"hljs-title\">a<\/span>&gt;&lt;\/<span class=\"hljs-title\">p<\/span>&gt;\n\t&lt;\/<span class=\"hljs-title\">form<\/span>&gt;\n&lt;\/<span class=\"hljs-title\">div<\/span>&gt;\n\n{%<span class=\"hljs-title\">endblock<\/span> <span class=\"hljs-title\">content<\/span>%}<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-9\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<h2 class=\"wp-block-heading\" id='configuring-smtp-for-sending-emails-from-the-django-app'>Configuring SMTP for sending emails from the Django app <a href=\"#configuring-smtp-for-sending-emails-from-the-django-app\" class=\"anchor\" id=\"configuring-smtp-for-sending-emails-from-the-django-app\" title=\"Anchor for Configuring SMTP for sending emails from the Django app\">#<\/a><\/h2>\n\n\n\n<p>To send emails in Django, you need to have a local Simple Mail Transfer Protocol (<code><code>SMTP<\/code><\/code>) server or an external <code><code>SMTP<\/code><\/code> Server from an email service provider.  <\/p>\n\n\n\n<p>Once having an <code>SMTP<\/code> server, you can add its information to the <code>settings.py<\/code> of the Django project with the following information:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>EMAIL_HOST<\/code>: the <code>SMTP<\/code> server host.<\/li>\n\n\n\n<li><code>EMAIL_PORT<\/code>: the <code>SMTP<\/code> port, the default is 25.<\/li>\n\n\n\n<li><code>EMAIL_HOST_USER<\/code>: The user name for the <code>SMTP<\/code> server.<\/li>\n\n\n\n<li><code>EMAIL_HOST_PASSWORD<\/code>: the password for the <code>SMTP<\/code> server.<\/li>\n\n\n\n<li><code>EMAIL_USE_<code>TLS<\/code><\/code>: whether to use the Transport Layer Security (<code>TLS<\/code>) secure connection.<\/li>\n<\/ul>\n\n\n\n<p>For example, the following shows how to use Google <code>SMTP<\/code> server settings:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-10\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">EMAIL_HOST = <span class=\"hljs-string\">'smtp.gmail.com'<\/span>\nEMAIL_HOST_PORT = <span class=\"hljs-number\">25<\/span>\nEMAIL_USE_TLS = <span class=\"hljs-literal\">True<\/span>\nEMAIL_HOST_USER = <span class=\"hljs-string\">'your_gmail_account@gmail.com'<\/span>\nEMAIL_HOST_PASSWORD = <span class=\"hljs-string\">'your_gmail_password'<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-10\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>Note that you should replace the <code>EMAIL_HOST_USER<\/code> and <code>EMAIL_HOST_PASSWORD<\/code> with your Gmail information.<\/p>\n\n\n\n<p>If you don&#8217;t have a local <code>SMTP<\/code> server, you can use the following value in the <code>settings.py<\/code> file:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-11\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">EMAIL_BACKEND = <span class=\"hljs-string\">'django.core.mail.backends.console.EmailBackend'<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-11\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>By using this setting, Django will output all emails to the console (Shell) instead of sending them. This is very convenient for testing without an <code>SMTP<\/code> Server:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-12\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">EMAIL_BACKEND = <span class=\"hljs-string\">'django.core.mail.backends.console.EmailBackend'<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-12\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>A sample output will look like this:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-13\" data-shcb-language-name=\"plaintext\" data-shcb-language-slug=\"plaintext\"><span><code class=\"hljs language-plaintext\">Content-Type: text\/plain; charset=\"utf-8\"\nMIME-Version: 1.0\nContent-Transfer-Encoding: 8bit\nSubject: Password reset on 127.0.0.1:8000\nFrom: webmaster@localhost\nTo: jane@pythontutorial.net\nDate: &lt;date&gt;\nMessage-ID:\n &lt;167014230656.23040.17412319412157509424@pythontutorial.net&gt;\n\n\nYou're receiving this email because you requested a password reset for your user account at 127.0.0.1:8000.\n\nPlease go to the following page and choose a new password:\n\nhttp:&#47;&#47;127.0.0.1:8000\/password-reset-confirm\/OA\/bfwytu-b9f9b789e9a294eb80d707e448dde1d2\/\n\nYour username, in case you\u2019ve forgotten: jane\n\nThanks for using our site!\n\nThe 127.0.0.1:8000 team<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-13\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">plaintext<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">plaintext<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>If you want to customize the password reset email, you can create a <code>password_reset_email.html<\/code> in the <code>templates\/users<\/code> directory:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-14\" data-shcb-language-name=\"HTML, XML\" data-shcb-language-slug=\"xml\"><span><code class=\"hljs language-xml\"><span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p<\/span>&gt;<\/span>Hi<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">p<\/span>&gt;<\/span>\n\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p<\/span>&gt;<\/span>You're receiving this email because you requested a password reset for your user account at {{domain}}\/<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">p<\/span>&gt;<\/span>\n\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p<\/span>&gt;<\/span>Please click the following link to reset your password:<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">p<\/span>&gt;<\/span>\n\n{{ protocol }}:\/\/{{ domain }}{% url \"password_reset_confirm\" uidb64=uid token=token %}\n\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p<\/span>&gt;<\/span>Thanks<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">p<\/span>&gt;<\/span>\n<span class=\"hljs-tag\">&lt;<span class=\"hljs-name\">p<\/span>&gt;<\/span>Todo App Team<span class=\"hljs-tag\">&lt;\/<span class=\"hljs-name\">p<\/span>&gt;<\/span>\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-14\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">HTML, XML<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">xml<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>And specify the <code>html_email_template_name<\/code> in the <code>as_view()<\/code> method of the <code>PasswordResetView<\/code> class:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-15\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">path(<span class=\"hljs-string\">'password-reset\/'<\/span>, \n     PasswordResetView.as_view(\n        template_name=<span class=\"hljs-string\">'users\/password_reset.html'<\/span>,\n        html_email_template_name=<span class=\"hljs-string\">'users\/password_reset_email.html'<\/span>\n    ),\n    name=<span class=\"hljs-string\">'password-reset'<\/span>\n)<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-15\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>If you reset the password, Django will use the custom email template instead:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-16\" data-shcb-language-name=\"Python\" data-shcb-language-slug=\"python\"><span><code class=\"hljs language-python\">&lt;p&gt;Hi&lt;\/p&gt;\n\n&lt;p&gt;Yo<span class=\"hljs-string\">u're receiving this email because you requested a password reset for your user account at 127.0.0.1:8000\/&lt;\/p&gt;\n\n&lt;p&gt;Please click the following link to reset your password:&lt;\/p&gt;\n\nhttp:&#47;&#47;127.0.0.1:8000\/password-reset-confirm\/OA\/bfwzqv-9d6b6777ad40073cfa1d4d4e150fb76f\/\n\n&lt;p&gt;Thanks&lt;\/p&gt;\n&lt;p&gt;Todo App Team&lt;\/p&gt;<\/span><\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-16\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">Python<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">python<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p class=\"note\">You can download the <a href=\"https:\/\/www.pythontutorial.net\/wp-content\/uploads\/2022\/12\/todo_list_9_password_reset.zip\" target=\"_blank\" rel=\"noreferrer noopener\">Django password reset source code<\/a> here.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id='summary'>Summary <a href=\"#summary\" class=\"anchor\" id=\"summary\" title=\"Anchor for Summary\">#<\/a><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Use <code>PasswordResetView<\/code>, <code>PasswordResetDoneView<\/code>, <code>PasswordResetConfirmView<\/code>, and <code>PasswordResetCompleteView<\/code> classes to implement the password reset function for the Django application.<\/li>\n<\/ul>\n<div class=\"helpful-block-content\" data-title=\"\">\n\t<header>\n\t\t<div class=\"wth-question\">Was this tutorial helpful ?<\/div>\n\t\t<div class=\"wth-thumbs\">\n\t\t\t<button\n\t\t\t\tdata-post=\"6126\"\n\t\t\t\tdata-post-url=\"https:\/\/www.pythontutorial.net\/django-tutorial\/django-password-reset\/\"\n\t\t\t\tdata-post-title=\"Django Password Reset\"\n\t\t\t\tdata-response=\"1\"\n\t\t\t\tclass=\"wth-btn-rounded wth-yes-btn\"\n\t\t\t>\n\t\t\t\t<svg\n\t\t\t\t\txmlns=\"http:\/\/www.w3.org\/2000\/svg\"\n\t\t\t\t\tviewBox=\"0 0 24 24\"\n\t\t\t\t\tfill=\"none\"\n\t\t\t\t\tstroke=\"currentColor\"\n\t\t\t\t\tstroke-width=\"2\"\n\t\t\t\t\tstroke-linecap=\"round\"\n\t\t\t\t\tstroke-linejoin=\"round\"\n\t\t\t\t\tclass=\"feather feather-thumbs-up block w-full h-full\"\n\t\t\t\t>\n\t\t\t\t\t<path\n\t\t\t\t\t\td=\"M14 9V5a3 3 0 0 0-3-3l-4 9v11h11.28a2 2 0 0 0 2-1.7l1.38-9a2 2 0 0 0-2-2.3zM7 22H4a2 2 0 0 1-2-2v-7a2 2 0 0 1 2-2h3\"\n\t\t\t\t\t><\/path>\n\t\t\t\t<\/svg>\n\t\t\t\t<span class=\"sr-only\"> Yes <\/span>\n\t\t\t<\/button>\n\n\t\t\t<button\n\t\t\t\tdata-response=\"0\"\n\t\t\t\tdata-post=\"6126\"\n\t\t\t\tdata-post-url=\"https:\/\/www.pythontutorial.net\/django-tutorial\/django-password-reset\/\"\n\t\t\t\tdata-post-title=\"Django Password Reset\"\n\t\t\t\tclass=\"wth-btn-rounded wth-no-btn\"\n\t\t\t>\n\t\t\t\t<svg\n\t\t\t\t\txmlns=\"http:\/\/www.w3.org\/2000\/svg\"\n\t\t\t\t\tviewBox=\"0 0 24 24\"\n\t\t\t\t\tfill=\"none\"\n\t\t\t\t\tstroke=\"currentColor\"\n\t\t\t\t\tstroke-width=\"2\"\n\t\t\t\t\tstroke-linecap=\"round\"\n\t\t\t\t\tstroke-linejoin=\"round\"\n\t\t\t\t>\n\t\t\t\t\t<path\n\t\t\t\t\t\td=\"M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3zm7-13h2.67A2.31 2.31 0 0 1 22 4v7a2.31 2.31 0 0 1-2.33 2H17\"\n\t\t\t\t\t><\/path>\n\t\t\t\t<\/svg>\n\t\t\t\t<span class=\"sr-only\"> No <\/span>\n\t\t\t<\/button>\n\t\t<\/div>\n\t<\/header>\n\n\t<div class=\"wth-form hidden\">\n\t\t<div class=\"wth-form-wrapper\">\n\t\t\t<div class=\"wth-title\"><\/div>\n\t\t\t<textarea class=\"wth-message\"><\/textarea>\n\t\t\t<input type=\"button\" name=\"wth-submit\" class=\"wth-btn wth-btn-submit\" id=\"wth-submit\" \/>\n\t\t\t<input type=\"button\" class=\"wth-btn wth-btn-cancel\" value=\"Cancel\" \/>\n\t\t<\/div>\n\t<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>In this tutorial, you&#8217;ll learn how to implement the Django Password Reset feature that allows users to reset their passwords using email addresses.<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":5531,"menu_order":20,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-6126","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/pages\/6126","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/comments?post=6126"}],"version-history":[{"count":0,"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/pages\/6126\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/pages\/5531"}],"wp:attachment":[{"href":"https:\/\/www.pythontutorial.net\/wp-json\/wp\/v2\/media?parent=6126"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}