0

I have a user role for content managers and I don't want to give them the permission to administer users. I do want them to have the ability to change their passwords so they aren't stuck with the temporary one I set them up with.

I have been able to add a link to their own 'edit profile' page on the default user landing page, and the link works and displays the change password form as expected. If they try to change their password, they are then given an access denied error because they are not authorized to view /admin/people, which is where they are sent after a password change.

HOWEVER: THE PASSWORD DOES GET CHANGED

So, it's confusing to the user because they think their password change has failed when it hasn't.

Is it possible to change what page they are directed to after a password change? I would prefer to send them back to their profile or even the homepage. (I would REALLY like to send them right to the content page so they can get to work.)

I would even settle for being able to edit the access denied error to better explain the situation to them.

1 Answer 1

2

Something doesn't add up with what the information you have given. When a user edits their own profile, the default is to simply reload the same page.

You said that you have added a link on their profile (view) page, that points to the user edit page.

I'm guessing that the following is part of the link you've added:

destination=admin/people

If there is, then you need to remove this. Anytime there is a destination=[SOMEPATH] in the URL and a form is submitted, it will redirect the user to the path given in the URL.

2
  • it was 'destination' instead of redirect but yes, that was exactly the problem. I changed it to destination=admin/content and now it takes them right where I want it to. Thanks! Jan 12, 2017 at 2:01
  • Oops, I was having a stupid moment. I altered my post accordingly. Glad it helped you out.
    – Jaypan
    Jan 12, 2017 at 2:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.