How to set custom template in Class PasswordResetView

425 views
Skip to first unread message

Rohan Purekar

unread,
Jun 13, 2017, 4:46:26 PM6/13/17
to Django users
I have implemented class based password reset view as instructed in django1.11 but the template being used is the default template, I want to use a custom template. Where I am stuck is If I have to use a custom template then I will have to call get and post functions to return the template to be rendered but what do I write in those functions I am not getting that part. 

Thanks in advance

Tim Graham

unread,
Jun 13, 2017, 7:50:18 PM6/13/17
to Django users
What does your code look like now? You can subclass the PasswordResetView and set the appropriate attribute for whichever template you want to override.

https://docs.djangoproject.com/en/dev/topics/auth/default/#django.contrib.auth.views.PasswordResetView

Or you can override the default template: https://docs.djangoproject.com/en/dev/howto/overriding-templates/
Reply all
Reply to author
Forward
0 new messages