Skip Navigation

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

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

Supporter timezone: America/Lima (GMT-05:00)

Tagged: 

This topic contains 6 replies, has 2 voices.

Last updated by Andreas W. 11 months, 1 week ago.

Assisted by: Andreas W..

Author Posts
October 1, 2022 at 5:32 pm #12161615

steveO-2

After filling out a GF registration form the user account will get activated at Forms > Entries.

Here we use site default language FR and the first activation email will be sent in FR instead of user language EN - all other notification emails seem to work fine - no matter which admin language is set.

October 1, 2022 at 7:12 pm #12161865

steveO-2

Hello,

The test site should be all configured to reproduce the issue.

I see you have a catchall plugin in place to debug.

I filled a form in french, and activated the user using english admin, and the confirmation email was sent in english.

October 2, 2022 at 3:20 am #12162623

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

Hello,

I have been testing again:
1) User fills out a form
2) A confirmation email is sent and it is always sent in the user language - works as expected

In your last message, you are mentioning a form confirmation message which is actually what you see on Frontend after filling out the form - you mean instead the user activation notification, correct?

1) User fills out a form in FR and received a confirmation email in French
2) Activating the user from Forms > Entries with admin language EN - notification is sent in EN
3) Sending another notification with admin language EN - notification is still sent in EN
4) Switching admin to FR - notification is still sent en EN

Example notification:

User Is activated
Thank you for joining us

Here's your link to set the password: Link

Is this the message that you refer to?

According to Form > Settings > Notifications > User activation the content should be:

Merci de vous joindre à nous

Voici le lien de configuration de votre mot de passe: <a href="{set_password_url}">Link</a>

I can confirm that this is located and translated correctly on WPML String Translation.

It is sadly unclear to me until now why GF always sends the notifications always in EN.

Before I escalate this issue, could you please confirm if I captured this correctly?

Best regards
Andreas

October 5, 2022 at 1:04 am #12181289

steveO-2

Hello,

My bad I replied to the email thinking it would update this thread.

Yes, what you are describing is correct.

The only way to send the activation email in french is to go on the admin account under Users > Profile and switch the language to french in there.

Thanks

October 6, 2022 at 1:47 am #12189525

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

Hello,

My apologies for the delay in answering, as I was debugging and trying to provide you with a workaround for the issue, for I have tried to analyze our Gravity Forms Multilingual Addon for the cause of this behavior.

In fact, it appears, that our code somehow seems work like that, that we recognize the current user on FrontEnd and set the correct profile language for this user inside the database when filling out the form. (FrontEnd-Operation)

But then, when the admin forces the email from the backend this current user relates to the admin, as this is the actual WordPress user in this case, while on activation or notification we actually should look for the user that originally filled out the form - or to be more clear the user field of the current post object "Entries".

Sadly, until now, I can not provide a workaround for this problem, and I have escalated this now to our compatibility team for further revision.

As soon I received further feedback from the team I will be in contact.

Best regards
Andreas

October 20, 2022 at 4:48 am #12275221

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

Hello,

The reported issue has been escalated to our development team and a fix for this issue will be implemented into an upcoming version of the Gravity Forms Multilingual Addon.

For now, I would kindly like to apply the following workaround in order to solve this issue:

Inside the file:

wp-content/plugins/gravityforms-multilingual/classes/compatibility/user_registration/Hooks.php

Add this condition:

       if (is_admin() && isset($_POST["action"]) && $_POST["action"] == "gf_user_activate" && $update == true) {
            do_action('wpml_switch_language_for_email', $user->user_email);
        }

right before :

		return $meta;

Please let us know if you need assistance with applying this code.

Best regards
Andreas

function.png
May 14, 2023 at 11:41 am #13642765

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

Hello,

I realized that we still have this ticket internally escalated and it looks to me that this should have been solved in GFML 1.7.0 while we are now running 1.7.2.

Could you please confirm and let me know if further assistance is needed?

Best regards
Andreas

The topic ‘[Closed] Gravity Forms User Registration Add-On – Activation email is not getting translated’ is closed to new replies.