Basically, all I need to change from the original link is:
action=rp
into rcp_action=lostpassword_reset
and then it works.
and maybe the @ sign (or any + signs) should be sanitised too in the future if possible.
-
This reply was modified 7 years, 1 month ago by meadows19.
Plugin Author
bnfw
(@voltronik)
Hi @meadows19,
Thanks for your message.
Your right in that would be useful. Currently there’s no way to change this within BNFW but it is something I have on the roadmap.
For now, unless you’re happy re-writing the lost password reset URL on the fly using some kind of regex redirection then I’m not sure how possible it will be to do this unless RCP has an option to disable their functionality that they add to the URL.
Thanks,
Jack
Hello,
Thank you very much for your ideas.
I looked into regex redirection as you mentioned and found that using a plugin called ‘Redirection’ I can use this regex:
replace /(\?action=rp&key=)(.*)
with \?rcp_action=lostpassword_reset&key=$2
and that seems to do the job.
It’s less than ideal because I already have about 60(!) plugins on my site, and I’m loath to add a significant new one (Redirection) just for this one-off small job.
I’d much rather just go into the code for BNFW and, say, edit any reference to action=rp
and replace it with rcp_action=lostpassword_reset
.
Not a good idea to edit plugin code, I know, but I actually tried that first and I couldn’t get it to work.
Is there any way of doing that? If not, I guess I’ll just have to stick with the Redirection solution for now.
Plugin Author
bnfw
(@voltronik)
Hi @meadows19,
Glad it’s working with the regex redirection using the Redirection plugin.
I use that plugin too and the main BNFW website is running over 60 plugins so understand your concern to add another one. It’s possible you can do this in your htaccess file instead (if you have access) which might be a better option for you if you don’t think you’ll need to add further redirects in the future.
I’ve added details of plugins that modify the password reset url in this way to the roadmap in the hope that I can provide better compatibility in the future.
Thanks,
Jack
Thank you, I will look into modifying the htaccess file as you suggested.