This thread is resolved. Here is a description of the problem and solution.
Problem:
The client was facing issues with the default WooCommerce pages such as Cart, Checkout, My Account, etc., not working in secondary languages.
Solution:
We discovered that the client had translated some non-translatable WooCommerce Endpoints, which was causing the problem. We advised the client to:
1. Not translate non-translatable endpoints.
2. Only translate endpoints that appear in the frontend for users.
3. Remove the incorrect translations of the endpoints from their site.
4. Use hyphens between words when translating Endpoint strings to prevent further issues.
After following these steps, the issue was resolved.
If this solution does not apply to your case, or if it seems outdated, we recommend checking the related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the problem persists, please open a new support ticket with us.
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.
Tagged: Bug
This topic contains 11 replies, has 2 voices.
Last updated by Bigul 9 months ago.
Assisted by: Bigul.
Author | Posts |
---|---|
April 4, 2024 at 2:36 pm | |
mariaL-30 |
I think I have everything configured correctly, but in the secondary languages, the default pages such as Cart, Checkout, My Account, etc. do not work. The main language is English and the secondary languages are French, Spanish, Dutch, and Italian. But I can't get them to work in the secondary languages. Could you help me and tell me what I have configured wrong? |
April 4, 2024 at 3:50 pm | |
April 5, 2024 at 10:32 am #15487429 | |
mariaL-30 |
Hi, New threads created by Bigul and linked to this one are listed below: https://wpml.org/forums/topic/php-warning-preg_replace-unknown-modifier-f-in/ |
April 5, 2024 at 12:43 pm #15488218 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, I had a few rounds of testing locally. The bug is existing after the initial checks. So I am consulting with our second-tier team for an expert opinion now. Therefore it will be great if you can wait until Monday(because of the weekend and this requires further debugging). Thank you for your kind understanding. -- Bigul |
April 8, 2024 at 7:13 am #15492668 | |
mariaL-30 |
Ok, waiting for news! Thanks, Maria |
April 8, 2024 at 3:39 pm #15495316 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, We are trying the possible workaround in this case. Now the Spanish and Italian posts are working as expected only if we choose the *Plain* option for the *Permalink structure*(from Settings>>Permalinks). It looks like this error is related to the following warning. So we are trying to fix this one first. PHP Warning: preg_replace(): Unknown modifier 'f' in \wp-content\plugins\sitepress-multilingual-cms\classes\url-handling\class-wpml-endpoints-support.php on line 142 We will update you on the status tomorrow. Please wait. -- Bigul |
April 9, 2024 at 7:25 am #15497100 | |
mariaL-30 |
Ok, thanks! I hope you can solve the problem, if not it's really a lot of work lost! |
April 10, 2024 at 8:43 am #15502862 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, Sorry for the delay. It is more tricky than expected. The Italian and Spanish pages/posts show the expected results only when WooCommerce is inactive. So the ticket is escalated to our second-tier team for further debugging. We will get back to you soon. Please wait. I appreciate your patience. -- Bigul |
April 10, 2024 at 9:47 am #15503525 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, We found the reason for this conflict. You have translated a few of the non-translatable WooCommerce Endpoints like wc/file/transient and wc-api. That is causing the issue. We don't have to translate all the endpoints, only translate the ones showing in the frontend for users. Removing those translations from your site has fixed the issue. Also, please put hyphens between the Endpoint strings while translating to avoid any further issues. Please check it now and let us know your feedback. Refer to the attached images for more details. -- Bigul |
April 10, 2024 at 9:57 am #15503594 | |
mariaL-30 |
Hi Bigul, I believe that he misled me when he told me that a translation was necessary. |
April 10, 2024 at 10:24 am #15503707 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, Thank you for the updates. Happy to know you are getting the expected results now. We have removed the problematic translations already. So keep it as like now. Please go through the Italian and Spanish pages now and ensure it working as expected or not. -- Bigul |
April 10, 2024 at 10:37 am #15503835 | |
mariaL-30 |
Hi Bigul, |
April 10, 2024 at 3:30 pm #15505678 | |
Bigul Supporter
Languages: English (English ) Timezone: Europe/Vienna (GMT+01:00) |
Hi Maria, Thank you for the feedback. You are welcome. We are happy to help always. Please feel free to ping us if you need any further assistance with WPML. -- Bigul |