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: Africa/Cairo (GMT+03:00)

This topic contains 4 replies, has 1 voice.

Last updated by Osama Mersal 2 months, 3 weeks ago.

Assisted by: Osama Mersal.

Author Posts
March 19, 2025 at 4:54 pm #16836582

michaelG-25

<b>Hintergrund des Themas: </b>
I am trying to add products to the cart on my website, but sometimes the 2nd, 3rd, or 4th/5th products disappear. We have tested this extensively and cannot recreate the issue on our staging site. We noticed that changing the settings 'Synchronize cart content when switching languages' to 'Prompt for a confirmation and reset the cart' makes the cart work as expected in the default language German, but not in English or French.
When navigating in the EN or FR version, when clicking on the first or second link (going to a Product page, Cart page or any other page) we get the notification "Switching language? You have switched language..." with the buttons "Keep EN" or "Switch back to DE" -> when clicking on either button, the cart gets emptied. For example I add a product to the cart and click on the cart link, notification pops up and cart gets cleared. If i navigate instead of going to the cart to another product, same popup and cart gets cleared.

Example link to a page where the issue can be seen: hidden link

<b>Die Symptome: </b>
When settings are for both Language and Currency set to 'Synchronize cart content when switching languages', items disappear from the cart in all languages. When settings are set to 'Prompt for a confirmation and reset the cart', the German cart works, but the English and French carts do not work. Navigating in EN or FR triggers a notification 'Switching language? You have switched language...' with buttons 'Keep EN' or 'Switch back to DE', and clicking either button empties the cart. Adding a product and clicking on the cart link or another product triggers the same popup and clears the cart.

<b>Fragen: </b>
Why do items disappear from the cart when NOT switching languages?
How can I prevent the cart from being cleared when navigating in English or French without changing language?

we have reviewed this help article: https://wpml.org/documentation/related-projects/woocommerce-multilingual/clearing-cart-contents-when-language-or-currency-change/?utm_source=plugin&utm_medium=gui&utm_campaign=wcml

March 20, 2025 at 12:04 pm #16839850

michaelG-25

Since yesterday, we have figured out that if we disable multicurrency, the cart works as expected. When we do have multicurrency activated, our developer noticed, that the wcml_client_currency_language cookie switches languages without manually changing locales...

Multicurrency is crucial for our shop and we need a solution as soon as possible. Please let us know how you can assist. If you provide a form, I can create a user for you to have access to WordPress.

March 23, 2025 at 2:58 am #16848149

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi,

Thanks for contacting WPML forums support. I'll be glad to help you today.

First of all, sorry for the late reply; it was due to a higher workload.

Please go to WooCommerce-> WooCommerce Multilingual-> Settings tab-> Cart section, select Synchronize cart content when switching languages in both options, then save.

Best regards,
Osama

March 24, 2025 at 8:16 am #16850051

michaelG-25

Hi Osama
Thanks for your respond. Please note, that when we have the settings "Synchronize cart content when switching languages" for both options, items disappear from the cart. You can observe this issue on the live website lavie-home.ch.

We have narrowed down the issue for items disappearing from the cart to the currency switcher. When we disable the multi currency option in WordPress - Woocommerce - Multicurrency - Multicurrency tab - disabled, the cart works as normal. Once activated, items disappear.

Our developer found these issues:
- found inconsistent wp-wpml_current_language values
- site will at random times switch from German default language to /en/

Can you please help us with this issue as soon as possible! Our webshop is not working properly and it needs fixed urgently.

Thank you

Makoto

Screenshots show current settings

Screen Shot 2025-03-24 at 9.13.51 AM.png
Screen Shot 2025-03-24 at 9.13.38 AM.png
March 24, 2025 at 4:49 pm #16853397

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi,

Thanks for your update. I would need to look closely at your site, so I would need to request temporary access (WP-Admin and FTP)
Preferably to a test site where the problem has been replicated.

Your answer will be private, meaning only you and I can access it.

❌ Please back up your database and website ❌

✙ I need your permission to deactivate and reactivate the plugins and themes and change site configurations. This is also why the backup is critical.

✙ I also need your permission to take a local copy of your site to debug the issue without affecting your live site.

Best regards,
Osama

The topic ‘[Closed] Issues with cart dropping products’ is closed to new replies.