[Resolved] Variation Gallery Image not showing in second language
This thread is resolved. Here is a description of the problem and solution.
Problem: The client was experiencing an issue where variation gallery images in WooCommerce products were not displaying in the translated version of the product. Instead, the main product image was shown.
Solution: 1. We suggested checking the translation preference for the Variation image gallery upload field. This can be done by navigating to WPML > Settings > Custom Field Translation and setting the translation preference to "Copy". 2. We requested the WPML Debug Information from the client to further investigate the issue. Instructions on how to obtain this information can be found here: https://wpml.org/faq/provide-debug-information-faster-support/. 3. For the issue with the attribute 'Taglia' not appearing correctly in the translated product, we found that the Text Swatch option in the Translated Attribute term was deactivated. Activating this option resolved the issue, and the variations began displaying correctly.
If you're experiencing a similar issue, we recommend trying the steps outlined above. However, please note that the solution might be irrelevant due to being outdated or not applicable to your case. If these steps do 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. Should you need further assistance, please do not hesitate to open a new support ticket: https://wpml.org/forums/forum/english-support/.
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.
Client asked to open a ticket instead of chat. The issue is that the variations are using a gallery image and the gallery image does not show in the second language, it shows the main product image instead.
In my woocommerce site I'm using Variable product.
A standard product have one Main Product image (that in the screenshot you can distinguish because of a small green arrow) and also gallery images (a yellow t-shirt and a red card).
When you create a variable product you can also set an image for every Variation and one or moregallery images (please have a look to screenshot - bue arrows).
Now after creating a product in primary language, I translate them with Woocommerce->Woocomemrce multilingual. I get a good translation, BUT the 'variation gallery images' (blue arrows in the screenshot) are missing, so the Main gallery images (purple arrows) are provided instead of the Variation gallery image in the translated product
So it seems that WPML for some reasons doesn't replicate in the translated product the variation gallery images. So Woocommerce replace it with the Product Main gallery images (as it usually do if you don't set any Variation Gallery Images)
I know that my explanation is difficult and complex, but the issue is quite simple: the Gallery images of the Variation items are lost.
But in the primary language everything is ok.
Url of the primary language product (working well)-> hidden link
Url of the primary language product (Missing Variation gallery images)-> hidden link
I'm waiting your reply to give site credential in the private panel here in support ticket.
Many thanks!
Looking better in Secondary language Product page editor, I can see in fact that Variation Image Gallery is empty (while in the primary product an image was selected). But all the fields are locked, so I can't add images from here.
It is possible that I have to set something in WPML setting to add Variation Image Gallery to the translatable fields?
Thanks
I understand the issue you're having. After reviewing the English version of the product, it appears that the same gallery images are loading in the English version, that are available in the default version. For clarity, please refer to this screenshot: hidden link.
The Gallery image may have been updated, which might explain why the issue isn't apparent in the translated version of the product at the moment. However, you mentioned in your previous message that the Variation Image gallery section of the translated product is not showing any images. Since this isn't a standard feature of WooCommerce, could you please clarify how this functionality was added?
Maybe setting the translation preference for the Variation image gallery upload field to "Copy" under "WPML > Settings > Custom Field Translation" might address the issue. If you could provide the WPML Debug Information in your next message, I would be able to examine it further and offer more specific advice.
In your reply You wrote: issue isn't apparent in the translated version->It's the opposite. The issue verifies in the translated product where Variation Image gallery is missing,
You also write that Variation gallery is not a standard Woocommerce. In my experience it comes with your partner theme Woodmart. Probably with Welaunch that is included in the theme.
I've to try what yo suggest 'Maybe setting the translation preference...'. I'm not confident into that part of wpml..
OK!!!!
thanks for you last indication: I do what you suggested. With Copy it doesn't work because when it opens the translation panel the Variation images don't appear, but if I set to Translate, they appear. Great solution.
Thanks a lot.
I ask you another thing also related to Variable product. If you look at the the product page (that is in english) you can see that the size selector is a vertical menu, while the original product page (italian) is a orizzontal selector (that can show all the size and you can check them. Can be possible to solve this issue? it seems the translation leave behind this element shape/layout.
Thanks again!
I'm glad to hear that the previous suggestion helped in resolving the issue!
As for the issue with product variations, it appears that the variation swatches in the original product are added by the Woodmart theme. The likely cause for the variation swatches not appearing on the translated product might be due to the configuration not being copied to the translated product, resulting in the translated product's variations defaulting to WooCommerce's standard dropdown method.
To address this, could you please try the following steps to see if it resolves the problem?
- Navigate to WPML > Settings and scroll to the section titled "Custom Term Meta Translation."
- Adjust the translation preference for the 'pa_taglia' meta to "Copy."
- Then, proceed to "Products > Attributes > Taglia > Configure Terms."
- For each term, select "Quick Edit" and simply update the term without making any changes.
I hope this will help. Please give it a try and let me know the update. I will be happy to help if you need further assistance in this matter.
Hi, thanks for your reply,
so, first issue is OK, for the second issue, I like very much what you suggest. It seems logical.
But by searching for pa_taglia it doesn't find nothing. I can find, searching for 'Taglia', (but in Custom Field Translation, not in Terms): 'attribute_pa_taglia'. (attached image)
Before doing something wrong, could you please tell me if it can be the right path to a solution and if so, how to proceed (copped, translate...and so on).
Many thanks!
We want to copy the Variation swatch settings to the translated attribute term, therefore, we will be updating the translation preference for the Terms only, not the custom field.
Since it is not visible and to better understand the root cause of the issue, a closer inspection will be required. I would like to request temporary access (wp-admin and FTP) to your site to take a better look at the issue. It would be better to have a testing site where the issue is replicated.
You will find the needed fields below the comment area when you log in to leave your next reply. The information you will enter is private which means only you and I can see and have access to it.
Maybe I'll need to replicate your site locally. For this, I’ll need to temporarily install a plugin called “Duplicator” or "All in One WP Migration" on your site. This will allow me to create a copy of your site and your content. Once the problem is resolved I will delete the local site. Let me know if this is ok with you.
IMPORTANT
-Please backup site files and database before providing us access.
-If you do not see the wp-admin/FTP fields this means your post & website login details will be made PUBLIC. DO NOT post your website details unless you see the required wp-admin/FTP fields. If you do not, please ask me to enable the private box. The private box looks like this: hidden link
I've tried to access your site but have been experiencing difficulty accessing the site. Every attempt results in an error stating "the site is currently unable to handle this request." Here's a screenshot for reference: hidden link
Could you please check why it is happening? If there are specific access rules or requirements, kindly share them so I can check accordingly.
hi sorry for that.
the fault is of one plugin (woosatispey) that was under auto-renew condition. its last version create crash. now it's ok.
thanks again and excuse for the accident
Upon checking, I noticed that the "Taglia" attribute was unexpectedly missing from the Custom Term Translation section. Since it is a global attribute, it should appear in the list. However, the underlying issue turned out to be that the Text Swatch option in the Translated Attribute term was deactivated. Once I activated this option, the variation began displaying correctly, as it appears in the default product.
To see the adjustments I made and how the variations are presented, please watch this video: hidden link
Please let me know if that helps or if you need further assistance in this matter. I will be happy to help.
hi Prosenjit,
many thanks for your job!
Really great. I've just to ask another minor thing If you look at size selector in main language (italian) you can see that sizes order: S-M-L-XL is not the same in secondary language (english) where is L-XL-S-M.
So I went to Product->english version of the product->attributes to put in order, but I found everything locked. So the first question is: is it the right way to change the order in the english product? Second question is: is it possible to unlock those attribute to put them in right order.
You can adjust the order of the Attribute terms by dragging them from the "Products > Attributes" section. To understand the process, please check this video: hidden link
I hope it will help. Please feel free to let me know if you need additional assistance in this matter. I will be happy to help.