Skip Navigation

[Escalated to 2nd Tier] wpv-forgot-password-form not working correctly

This support ticket is created 2 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 56 replies, has 4 voices.

Last updated by Luo Yang 2 years, 2 months ago.

Assisted by: Luo Yang.

Author
Posts
#2280591

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hmm. On my copy of your site the reset password workflow doesn't complete, even in English, it complains about an invalid key.

I double-checked on my own test site, and confirm that it works—with or without the patch.

I'll keep digging to understand why it is a problem on your site, but I'm sorry this will take some time.

#2280899

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

OK, it took me most of the day going through multiple tests to realize that the workflow was failing because the WPML setting "Allow translating the login and registration pages" was checked, but must be unchecked, as we are not using the normal WordPress reset password workflows and instead using that coming from Views/Blocks.

Re-instating the patch on your test site, the workflow is now correctly maintained in German throughout the process.

The one remaining problem is that the text of the reset password notification email is in English, even though I can see translations of the texts are available.

I will try and solve that piece of the puzzle tomorrow.

#2280933

Hi Nigel

Thanks for all your continued efforts!

I unchecked that WPML option and re-applied your patch on our dev server.

English PW reset works flawlessly, however clicking the link in the email from the German version of the lost password process, I am still getting that redirect from the German page "passwort-zuruecksetzen" to the English "reset-password" page.

hidden link >> hidden link

HOWEVER, if I copy and paste the link into the browser, I CAN open the German page "Passwort zurücksetzen" (reset password). I can enter a new PW twice there, and am redirected to the PW Change Successful page in German as I would expect. The password is reset and the PW reset successful email confirmation goes out, unfortunately also in English again.

Have you any idea why this redirect is occurring? It's strange that when I paste in the URL it works, but clicking the URL from the email loads the (correct) German page, then redirects.

Kind regards
Simon

#2281577

Hi Nigel

Quick update. My colleague’s computer’s OS is in German. On her computer it works fine in German so I think it was just my browser redirecting to English because my OS was in English. In fact hers behaves the exact opposite of mine. German works perfectly but clicking the English version of the link gets redirected to the german page.

Could this be cookie related?

Kind regards
Simon

#2281663

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

I think that is because you have the setting to redirect based on the browser language.

Go to WPML > Languages and disable the "Browser language redirect" setting.

#2281735

HI Nigel

That worked. So I can now confirm that the process works 100% in English and German and the only remaining issue is why we aren't getting German emails when we do the process is German.

This is a great progress, thank you!

Kind regards
Simon

#2282641

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

OK, for hopefully the last time (fingers crossed), I have a solution which I've tested on my local copy of your site and which works both for the English and German reset password workflows.

Please try again with this new patched file: http://toolset.com/patches/wpv-shortcodes.php.zip

Replace the wpv-shortcodes.php in the directory plugins/toolset-blocks/embedded/inc/ with this new patched file.

Let me know how it works out. If you confirm it works I'll share the proposed solution with the developers.

#2282913
Screenshot 2022-02-03 at 16.37.54.png

Hi Nigel

Thank you so much for the patch! 😊

I applied it and it translates the first mail correctly, but the simple confirmation mail that is sent once the password has been changed successfully is still coming in English for the German version. I found two strings in WPML for that email and they are both translated on our site (see screenshot).

Kind regards
Simon

#2283605

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hi Simon

That is an admin message sent to the site owner to tell them that someone changed their password, not an email sent to the user who went through the password reset process.

So it is somewhat different, and it is not obvious to me that it should get translated. As an admin notice, I would expect it to be sent in the default language of the site. (Imagine the site had 10 languages; I wouldn't expect the site admin to receive admin notices in 10 different languages.)

What do you think?

#2283633

HI Nigel

Yes, you are right. It is indeed just for us as admins, so it's totally fine that that happens in English only, since our site is set to English UK. In that case, I would say that your patch is working! 😊 ✅

Kind regards
Simon

#2286429

Is this problem fixed? please let me know if you need more assistance for it

#2286565

Hi Luo

Nigel has given me a workaround patch which we can use successfully for now.

Please mark the ticket as Escalated to 2nd tier and update me when the plugin contains the fix permanently.

Regards
Simon

#2287279

Escalated.