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.

Our next available supporter will start replying to tickets in about 6.35 hours from now. Thank you for your understanding.

Tagged: 

This topic contains 13 replies, has 3 voices.

Last updated by Nicolas Viallet 1 year, 7 months ago.

Assisted by: Nicolas Viallet.

Author Posts
September 8, 2022 at 1:58 pm #12014737

Javier

Follow up for https://wpml.org/forums/topic/wrong-language-appearing-in-the-order-url/

September 8, 2022 at 5:10 pm #12016757

Javier

Hello, please assign this ticket to Nicolas V. as he was managing the original ticket:
https://wpml.org/forums/topic/wrong-language-appearing-in-the-order-url/

Nico, please let me know if the domain and access to the sandbox is still available and I can proceed to create a product as you requested.

Thank you

September 9, 2022 at 11:21 am #12021609

Yvette
Supporter

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

Timezone: Europe/Paris (GMT+02:00)

OK - reassigning.

September 9, 2022 at 3:54 pm #12023577

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hello Javier,

Sandboxes are only available for 7 days so the one in your previous message expired already.

But don't worry I have created a new one here:
hidden link (one click login)

- I would need you to set up WPML + the WPML add-ons + WooCommerce as you have them on your site (they are already installed) and try to recreate the issue.

Please don't install any other plugins that are not necessary to reproduce the issue.

- If the issue is reproduced on that clean setup, then I can forward this to our 2nd tier support team.

Nico

September 15, 2022 at 11:20 am #12058837

Javier

Hi I am setting up the sandbox, I have noted the following issues:
* cannot set-up a subdomain structure as on our site, it would have been hidden link
* cannot translate the attribute I set-up in English (brand and then value VOGLAUER)
* when I create the draft product, I can't access the French translation:
hidden link
How do I translate it?

Thanks

September 15, 2022 at 6:38 pm #12063069

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hi Javier,

I had a quick look and "WooCommerce Multilingual" was installed but not activated. I went ahead and activated it. You can now translate your attributes and products in "WooCommerce > WooCommerce Multilingual"
Attributes: hidden link
Products: hidden link

And yes, you're right about the Language URL format, it's not use to have domains or subdomains on sandbox sites but I don't think your issue is related to that configuration. So we should be able to reproduce it.

Nico

September 19, 2022 at 12:14 pm #12078643

Javier

Hello Nico,

Thank you for your help.

I have completed the French translation for the product I created in the sandbox.

I am then trying to create an order identical to the one we used as an example:
hidden link (this is the original screen shot from our prod environment)

I cannot seem to choose the right variations despite them being translated correctly:
On the product page they appear correctly translated (I used WPML product translator):
hidden link

but I notice that the name of the attributes has not been translated correctly as it appears in the French version:
hidden link

whereas in the WPML Product translation editor, it seems correct:
hidden link
see here please:
hidden link

Thanks!

September 20, 2022 at 6:32 pm #12089677

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hi Javier,

I'm not sure how did you set up the attributes but I went to "WooCommerce > WooCommerce Multilingual > Status" and click the link at the bottom right to access our troubleshooting tools. Then I sync'ed product variations and the issue was fixed.

Moreover I ordered in French and all attributes were correctly translated on cart, checkout, and order confirmation pages (see screenshots).

Please let me know what's the next step to reproduce the issue.

1.png
2.png
3.png
September 22, 2022 at 4:41 pm #12106089

Javier

Hello Nico, thank you for your support. I have tried now to have a look at the sandbox and the link has expired. Anyway, I am not sure how to proceed (or just give up) as I did create the product correctly and it seems you have the right kind of purchase confirmation email...

September 23, 2022 at 2:13 pm #12112143

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hello Javier,

The sandbox didn't expire yet I could access it. Here is the login link: hidden link

Please review the order and let me know what's the next step because I think that you were sending the link manually to the customer if I recall well? Also, please try to update WPML to 4.5.10 and String Translation to 3.2.2 because the errata I mentioned in our previous ticket has been solved in this last release: https://wpml.org/errata/woocommerce-e-mails-are-always-sent-in-default-language-for-any-admin-order-status-change/

Nico

September 25, 2022 at 10:37 am #12118685

Javier

Hello Nico, great idea since I have now reproduced the error I think.
First go to the order I made:
hidden link
As you can see there is a mix of French and English already:
hidden link

I changed the client to "guest" and then opened the "client payment page" (I often send them an email so they can pay using that link so it needs to look good in French). To have French and not English, I use the parameter for "fr" in the url:
hidden link

however, here, all looks good (it usually does on my production environment) but when the client pays (normally by credit card), then the ensuing order confirmation has mixed languages... on this order as it is payment upon delivery, I cannot pay the order on this screen and hence modify its status to "processing" and see what the order confirmation email looks like...
hidden link

I need to be able to simulate a payment of that order (so another payment method would be required) or perhaps you can now change the status to "processed" and send a confirmation email to see what it looks like? Would that be a good test?

Best Regards,

Javier Petrement

September 27, 2022 at 1:28 pm #12132057

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hi Javier,

Thank you! So it seems that the issue happens when you change the client to "guest".
I will make a video with the workflow you described and escalate the case to the second tier support.

I'll get back to you when I have their feedback.

Nico

September 28, 2022 at 7:45 pm #12144079

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hello,

Just a quick follow to share my findings:
- The top 3 attributes seem to always be in English (and the 2 last in French) as soon as you access the order from the admin, regardless of the options (attributes terms) chosen during the order.
- I checked if there was any difference between the 3 first and the last 2 attributes and the only thing I could find was that the 3 first ones are selected/defined in your variations while the 2 last ones are set as "ANY".

I'm not sure it it's related to the issue but the case has been escalated to an higher level for further debugging.

Thanks for reporting this and for your cooperation. I'll get back to you asap.
Nico

screenshot-2022.09.28-08_30_09.png
September 29, 2022 at 3:30 pm #12151241

Nicolas Viallet
Supporter

Languages: English (English ) French (Français )

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

Hello,

Thanks for reporting this. It seems to be a bug in that particular case scenario/workflow. After you removed your customer and set him as "Guest" the current user profile language will replace the customer language in the order items. So in our example because the admin profile is in English, the French order get mixed with English attributes.

We don't have a proper fix for that right now, the issue has been escalated to the developers and they will evaluate it and see if it can be fixed in a next release. So I can't provide you a ETA on that issue.

Here is a code hack you can use:
in wp-content/plugins/woocommerce-multilingual/inc/class-wcml-orders.php search for:

public function adjust_order_item_in_language

and just after the method start call 'return' so that the logic is not applied, like this:

public function adjust_order_item_in_language( $items, $language_to_filter = false ) {
return;

Nico

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.