auth.views.password_reset_confirm()

password_reset_confirm(request, uidb64=None, token=None, template_name='registration/password_reset_confirm.html', token_generator=default_token_generator, set_password_form=SetPasswordForm, post_reset_redirect=None, current_app=None, extra_context=None)

Presents a form for entering a new password.

URL name: password_reset_confirm

Optional arguments:

  • uidb64: The user’s id encoded in base 64. Defaults to None.
  • token: Token to check that the password is valid. Defaults to None.
  • template_name: The full name of a template to display the confirm password view. Default value is registration/password_reset_confirm.html.
  • token_generator: Instance of the class to check the password. This will default to default_token_generator, it’s an instance of django.contrib.auth.tokens.PasswordResetTokenGenerator.
  • set_password_form: Form that will be used to set the password. Defaults to SetPasswordForm
  • post_reset_redirect: URL to redirect after the password reset done. Defaults to None.
  • current_app: A hint indicating which application contains the current view. See the namespaced URL resolution strategy for more information.
  • extra_context: A dictionary of context data that will be added to the default context data passed to the template.

Template context:

  • form: The form (see set_password_form above) for setting the new user’s password.
  • validlink: Boolean, True if the link (combination of uidb64 and token) is valid or unused yet.

Deprecated since version 1.9: The current_app parameter is deprecated and will be removed in Django 2.0. Callers should set request.current_app instead.

doc_Django
2016-10-09 18:34:31
Comments
Leave a Comment

Please login to continue.