[Resolved] Bug in the appearance of the product bundle
This thread is resolved. Here is a description of the problem and solution.
Problem: If you're experiencing issues with the display of product bundle images in secondary languages on your WooCommerce site, and the images display correctly in the primary language but not in French or English, the issue might be related to the WPML configuration for the WooCommerce Product Bundles plugin. Solution: We recommend updating your WPML configuration manually until our compatibility team integrates the fix into the official WPML configuration files. Here are the steps you should follow: 1. Navigate to WPML -> Settings -> Custom XML Configuration tab. 2. Add the following XML code to ensure the custom fields are set to copy:
3. Click the Save button. 4. You may need to manually update each product bundle by editing the original bundled products in the primary language and clicking the Update button.
This solution might become outdated or might not apply to your specific case. If this solution does not resolve your issue, 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 further assistance is needed, please open a new support ticket.
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.
Contexte de la question:
I am trying to display a product bundle (mixed product in one) on my site hidden link in the 2 secondary languages. The display looks good in the Swedish master language.
Symptômes:
The images of the mixed products don't display correctly when switching to the 2 secondary languages French and English.
Questions:
How can I fix the image display issue for product bundles in the secondary languages?
Is there a specific WPML setting that needs adjustment for product bundles?
I want to add that going through the procedure, you recommended to update 3 plugins WooCommerce Multilingual & Multicurrency and 2 WPML plugins. However, when checking available updates, I seem to be updated in the backend.
The Product Bundles for WooCommerce plugin is officialy comtpatiable with WPML. https://wpml.org/plugin/woocommerce-product-bundles-2/
It should work fine. But, of course, we will continue to help you with this problem.
How have you translated this product?
Have you used WPML's Translation Editor, or used another method?
It's a product that was created last week with the WPML Translation Editor.
I must say that it's a tool that has been bugging a lot recently, blocking or not validating the steps of translations. The whole site was slowing down and showing instability through Jet pack. I updated the WPML plugins, but a part of the update wouldn't work and my webmaster had to intervene manually. Now it's better, but it's still slow and the bundles don't display correctly.
We try to focus on one issue per ticket in our technical support forum. Otherwise, tickets can get cluttered and confusing for both users and supporters. In this ticket, we are focusing on the Product Bundles for the WooCommerce layout problem. Please open a new ticket in our support forum for the other issue you mentioned.
We need to replicate this issue on a fresh WordPress installation. We need to see if there is a new problem with the Product Bundles for the WooCommerce plugin, which we are unaware of. Then, if the problem is replicable, I can escalate it to our compatibility team. For this, I created a test website with a clean WordPress install. You can access it through this link:
hidden link
With this link, you'll be directly logged in.
I already installed and configured WooCommerce. I also configured WPML to have Swedish as the default language and English as the second language. The Product Bundles for WooCommerce plugin is also installed. I installed the Storefront theme with some sample products.
Can you please check if the problem is replicable on the sandbox site?
Important! Do not import your site to the test site. We must replicate the problem on a fresh, clean WordPress installation.
Thanks for your help. I see for the focus, the rest is just for info and a complete understanding. I clicked your link and created a product calles test product bundles and the problem appears here as well.
1. First of all there's another bug (same on my site) : when you click the English flag after having created the product in both languages, you need to go back to the Swedish version and then click the flag again. Elsewise, the English version won't display.
2. When arriving to the English page and clicking "preview changes" on the English version, the bundled products don't show up at all so it's even worse then on my site where it's just the layout that is wrong.
I've further checked this problem and discovered the following.
1. On the sandbox site, the bundled products did not show up on the translated product because they were untranslated. Once I translated them, they showed up on the translated product with the same problem as on your site: the layout was different.
2. The problem derives from systems fields that are set as Don't translate where they should be set to Copy. Those are the fields 'Form location' and 'Item Grouping'. Their settings are not being copied over to the translated product. Please see the attached screenshot.
I've escalated this problem to our compatibility team, and I'll report back here once I have news about it.
As a workaround, please proceed with the following.
1. Go to WPML -> Settings and scroll to the Custom Fields Translation section.
2. Click the Show system fields option. It is under the Custom Fields Translation title.
3. Search for the following fields, set them to 'Copy', and click the Save button.
_wc_pb_group_mode
_wc_pb_add_to_cart_form_location
Please see the attached screenshot.
4. Edit the original bundled products in Swedish where the problem in English exists, and click the Update button. This will also trigger the change for the bundled translated product.
Thank you for your reply. I think you found something, however I still have a few comments :
1. I followed your process and for info the 3rd point :
"Search for the following fields, set them to 'Copy', and click the Save button.
_wc_pb_group_mode
_wc_pb_add_to_cart_form_location
Please see the attached screenshot."
won't leave the fields in the copy mode. I don't know if it should ? After "save", they go back to the initial mode. However, it modified the lastly created bundle which now displays correctly in all 3 languages.
2. There are still bundles that are not displaying correctly ex. hidden link . I didn't go through all of them since there are approx. 100 bundled products and I really hope I will not be obliged to go through them all. It would take days.
3. The speed has drastically gone down. I've been waiting 1-2 minutes before the bundled product display correctly. That was not the case when navigating on normal products just before. I will see if it gets better further on.
In summary, the solution is found, but not for all the products. The speed for displaying the products and switching between languages is far too long for keeping a client on the site.
Our compatiiblity team notified me that they will fix this problem in the wpml-config.xml file we have for the WooCommerce Product Bundles plugin. You can see it in the following link.
hidden link
Meanwhile you can add this plus the additions of the fields mentioned directly on your site. Here are the steps you should follow.
1. Go to WPML -> Settings -> Custom XML Configuration (tab).
2. Add the following XML code. The code includes the original fields plus the two fields with the probelm.
This should set the fields to Copy in a permenant way.
You wrote: "After "save", they go back to the initial mode."
This should not happen. The fields should stay with the Copy status after you click the Save button. In any case, adding the XML code as I explained above should make thier status as Copy fixed.
You also worte: " I didn't go through all of them since there are approx. 100 bundled products and I really hope I will not be obliged to go through them all. It would take days."
I'm sorry but you can't avoide from updating the products with this problem. This is what I explained in step number 4 in my previouse reply:
4. Edit the original bundled products in Swedish where the problem in English exists, and click the Update button. This will also trigger the change for the bundled translated product.
Finally about the speed issue you mentioned. This is a seprate issue that should be handled in a new ticket. We try to focus on one issue per ticket in our technical support forum. Otherwise, tickets can get cluttered and confusing for both users and supporters. If you need further help with the speed issue, please open new tickets for the other issues.
I'll keep you updated when I have news about this issue from our compatibility team.
Our compatibility team has informed me that the problem with this ticket has been solved. The XML code I shared with you is now included in our WPML configuration files.