Skip Navigation

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

Problem:
The client is experiencing an issue where adding 2x composite products to the cart on a translated page results in 4x components being added instead of the expected 2x. This problem does not occur on the original language page, suggesting it might be related to WPML.

Solution:
We recommend the following steps to address the issue:
1. Disable cart synchronization by setting it to the "Reset" option in the WooCommerce Multilingual settings. This can be done by turning on the "Prompt for a confirmation and reset the cart" option for language and currency changes.
2. Resolve the 404 image issue on the website. If uploading images for additional languages is not preferred, add the following code to the top of the .htaccess file and upload a placeholder.jpg to the site's root directory:

RewriteEngine on<br />RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f<br />RewriteRule \.(gif|jpe?g|png|bmp|webp) placeholder.jpg [NC,L]

After implementing these changes, please test to confirm that the issue is resolved.

If this solution does not seem relevant to your situation, 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.

This topic contains 17 replies, has 2 voices.

Last updated by Shekhar Bhandari 1 year, 6 months ago.

Assisted by: Shekhar Bhandari.

Author Posts
December 18, 2023 at 1:39 pm #15084719

Shekhar Bhandari
WPML Supporter since 03/2015

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hello there,

I am discussing the issue with our 2nd tier supporters now. I will update you here as soon as I will have further feedback.

Thanks

December 18, 2023 at 2:02 pm #15084863

jeppeK-2

Thank you, looking forward to hearing from you.

January 3, 2024 at 12:45 pm #15146494

Shekhar Bhandari
WPML Supporter since 03/2015

Languages: English (English )

Timezone: Asia/Kathmandu (GMT+05:45)

Hello there,

I've received feedback from the second tier. I apologize for the delayed response, but please understand that our availability of support staff has been limited due to the holiday season.

The issue you're encountering appears to be related to the use of multicurrency. When using "Woocommerce Composite Products," it's recommended to turn off cart synchronization and set it to the "Reset" option, as advised in the WooCommerce Multilingual notice. However, it seems that you may have dismissed the notice and kept the synchronization setting as is.

Currently, you're experiencing an issue with 404 images on your site at hidden link. These 404 images are in webp format and, when accessed, lead to the display of the primary language WP 404 page instead of the server's 404 page. You can observe this issue by visiting the following links:

1. hidden link
2. hidden link

You may notice that there's a clear distinction between these two links: one leads to the WP 404 page, while the other leads to the server's 404 page. When the WP 404 page is loaded, the cookie value is changed to "DA," and since cart synchronization is on, it disrupts the session cart, resulting in the issue you're facing.

To resolve this issue, we suggest the following steps:

1. Turn on the "Prompt for a confirmation and reset the cart" option for language and currency changes in your WCML settings. [WooCommerce->WooCommerce Multilingual->Settings]

2. Address the 404 image problem on your website. If you prefer not to upload additional languages, you can add the following code at the top of your .htaccess file and upload a placeholder.jpg file to the root directory of your site:

RewriteEngine on
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} !-f
RewriteRule \.(gif|jpe?g|png|bmp|webp) placeholder.jpg [NC,L]

After making these changes, please test the issue again to ensure that it has been resolved.

Look forward to your reply.

Thanks