Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client was facing an issue where despite translating everything in string translations, the cart was not translated. Additionally, a new cart page with the URL '/cart-2/' was automatically being created and set as the default, which was happening on multiple websites using WPML.
Solution:
We recommended checking if the 'Auto-generate from title' option was enabled in WPML>>Settings>>Translated documents options>>Page URL settings, as WPML follows WordPress guidelines for creating post slugs. If a post slug 'cart' exists, WordPress will automatically add 'cart-2' for a new post with the same slug. For more details, refer to the documentation on translating page and post URL slugs at https://wpml.org/documentation/getting-started-guide/translating-page-slugs/#translate-page-and-post-url-slugs and https://crocoblock.com/knowledge-base/articles/how-to-create-wordpress-slugs-and-permalinks/.

If this solution does not resolve your issue, or if it seems outdated or irrelevant to your case, we highly recommend checking related known issues at https://wpml.org/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 at WPML support forum.

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: 

This topic contains 7 replies, has 2 voices.

Last updated by Bigul 2 months, 1 week ago.

Assisted by: Bigul.

Author Posts
August 31, 2024 at 10:51 am #16127311

ziga pipan

Background of the issue:
I translated everything in string translations but it's still not translated in the cart. Checkout works ok. I enabled 'auto register strings for translations'. I scanned themes and plugins for new strings. I looked in 'Translate texts in admin screens'.

Symptoms:
Cart is not translated

Questions:
Why is the cart not translated despite translating everything in string translations?
hidden link
Is there a specific step I missed in translating the cart strings?

August 31, 2024 at 5:08 pm #16127981

Bigul
Supporter

Languages: English (English )

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

Hello,

Welcome to the WPML support forum. I will do my best to help you to resolve the issue.

Please try the following troubleshooting steps after a full site backup{mandatory} and make sure the issue exists or not.

1) Upgrade to the latest version of WordPress (6.6.1)

2) Increase *WP Memory Limit* to *256* MB(the minimum required memory limit for WPML is *128*). Please check the following links for more details

https://wpml.org/home/minimum-requirements/

https://developer.wordpress.org/apis/wp-config-php/#increasing-memory-allocated-to-php

3) Go to WPML>>Support page, click on the Troubleshooting link (blue link in the middle of the page)

4) On the Troubleshooting page, please click on the following options of the *Clean up* section. Wait for confirmation of processing after each one.

- Clear the cache in WPML
- Remove ghost entries from the translation tables
- Fix element_type collation
- Set language information
- Fix WPML tables collation
- Assign translation status to duplicated content
- Fix terms count
- Fix post type assignment
- Cleanup and optimize string tables
- Show custom MO Files Pre-generation dialog box>>Generate .Mo files

--
Thanks!

Bigul

August 31, 2024 at 5:21 pm #16127986

ziga pipan

I figured out what was wrong. My cart was not /cart but /cart-2.
I had two cart pages and when I deleted the new one all was ok.

Having said that, wpml keeps adding an additional /cart-2 page and making it a default one. This happens every few weeks and I have the same problem on multiple different websites. Is this something known to you?

September 2, 2024 at 9:35 am #16130757

Bigul
Supporter

Languages: English (English )

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

Hello,

Thank you for the updates. Hope you have added the secondary cart page from Pages>>All Pages. Normally WPML will not create a page or post automatically. Therefore it requires further checking.

So please share a screencast (Screen capture of the bug and you can share it via Google Drive or Dropbox) for a better understanding of the issue. The screencast will help us a lot in internal communications.

--
Thanks!

Bigul

September 2, 2024 at 12:33 pm #16131598

ziga pipan

For now I deleted the second page. Will let you know when there is an issue again.

Basically, a new Cart page appears with url /cart-2/ and it is made a default one.

What I then do is delete the page and set /cart/ page to be the default one in setting.

Problem is this is happening on almost every page that uses wpml, and it's hard to keep daily track.

September 3, 2024 at 12:39 pm #16135669

Bigul
Supporter

Languages: English (English )

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

Hello,

Thank you for the updates. We hope you are using WPML Advanced Translation Editor for translating the posts/pages and you have selected the *Auto-generate from title* option in WPML>>Settings>>Translated documents options>>Page URL settings.

WPML is following the WordPress guidelines for creating the post slug. So if there is a post slug *cart* that exists, WordPress will add *cart-2* as the slug for the new post with slug *cart*. Refer to the following documentation for more details.

https://wpml.org/documentation/getting-started-guide/translating-page-slugs/#translate-page-and-post-url-slugs

hidden link

Please share a couple of screenshots or a screencast (a screen capture of the issue and you can share it via Google Drive or Dropbox) for a better understanding of the following. It will help us a lot in internal communication.

Problem is this is happening on almost every page that uses wpml, and it's hard to keep daily track.

--
Thanks!

Bigul

September 3, 2024 at 1:40 pm #16135949

ziga pipan

I'm using a classic translation editor actually.

Also the problem seems to be gone with last few updates, will keep an eye on it tho.

thank you

September 3, 2024 at 3:30 pm #16136638

Bigul
Supporter

Languages: English (English )

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

Hello,

Thank you for the feedback. We are happy to know you are getting the expected results now. Take your time. We will wait for your updates.

--
Thanks!

Bigul