Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8177347
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T23:29:06+00:00 2026-06-06T23:29:06+00:00

I would like to allow the user to change the password and I am

  • 0

I would like to allow the user to change the password and I am using the django-in-built password_change function. I would like to use the default template-name and password_change_form but I want to change the post_change_redirect argument to specific to my website.

How do I change that only while keeping the rest the same?

From Django Documentation:

password_change(request[, template_name, post_change_redirect, password_change_form])
Allows a user to change their password.

URL name: password_change

Optional arguments:

template_name: The full name of a template to use for displaying the password change form. Defaults to registration/password_change_form.html if not supplied.
post_change_redirect: The URL to redirect to after a successful password change.
password_change_form: A custom "change password" form which must accept a user keyword argument. The form is responsible for actually changing the user's password. Defaults to PasswordChangeForm.
Template context:

form: The password change form (see password_change_form above).

Need some guidance. Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T23:29:07+00:00Added an answer on June 6, 2026 at 11:29 pm

    You want to define a view, which will be serving a modified password_change view:

    from django.contrib.auth.views import password_change
    
    def change_password(request):
        return password_change(request, post_change_redirect='%my_post_change_url%')
    

    And that’s all.

    You must only remember that, it’ll redirect you to the default login-page if you’re not logged-in and that you have to write a password change page template (named registration/password_change_form.html by default)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to allow a user to change his email address. A user
I've a user profile and would like allow the user update everything about himself(username,
I would like to allow the user to click within my UserControl and drag
I would like to allow a user to click on a JList and if
I'm creating a new WP theme and I would like to allow the user
I would like to create a new controller that will allow the admin user
I'd like to allow a user to add a shape (which would just be
I am using some tweaks that allow the user to change the UI of
I have a WPF Listbox control and I would like to allow the user
I would like to allow the logged user to edit MediaWiki/Common.css without adding them

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.