Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi All
Is there a way for Umbraco members to self-serve their password resets? (Without a website admin having to do it for them)
I have looked at various tutorials and forum posts and cant seem to find a definitive answer.
Any help on the subject would be great
Jack
Hi Jack
You need to create surface controller or api controller on backend code and form for members.
Try to look at this method:
[HttpPost] public ActionResult HandleUpdatePassword([Bind(Prefix = "passwordModel")]UpdatePasswordModel model) { try { if (ModelState.IsValid == false) { return CurrentUmbracoPage(); } var memberService = Services.MemberService; var member = memberService.GetById(AppHelper.GetCurrentUserId()); memberService.SavePassword(member, model.Password); TempData["UpdateSuccess"] = true; } catch { } return CurrentUmbracoPage(); }
It basically do what you need, adopt this code for your needs and it will work.
Read more about memberService, it has a lot of methods for working with members:
https://our.umbraco.org/documentation/reference/management/services/memberservice
Hope it will help.
Thanks.
Alex
Did you find out how to do your task?
Thanks,
Hi there,
Just wondering whether/how I'm able to add this without using Visual Studio? The Umbraco installation is already deployed and this is an additional functionality. Working on this project has shown me just how little I know about Umbraco!
Thanks
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Members Password Reset
Hi All
Is there a way for Umbraco members to self-serve their password resets? (Without a website admin having to do it for them)
I have looked at various tutorials and forum posts and cant seem to find a definitive answer.
Any help on the subject would be great
Jack
Hi Jack
You need to create surface controller or api controller on backend code and form for members.
Try to look at this method:
It basically do what you need, adopt this code for your needs and it will work.
Read more about memberService, it has a lot of methods for working with members:
https://our.umbraco.org/documentation/reference/management/services/memberservice
Hope it will help.
Thanks.
Alex
Hi Jack
Did you find out how to do your task?
Thanks,
Alex
Hi there,
Just wondering whether/how I'm able to add this without using Visual Studio? The Umbraco installation is already deployed and this is an additional functionality. Working on this project has shown me just how little I know about Umbraco!
Thanks
is working on a reply...