Display Linked Product Colors on Shop/Archives Page
-
Hello,
I recently purchased your theme and overall I’m happy with it, but there’s one issue that’s been bothering me.
I have linked products, each with a single color assigned. On the single product page, the colors (i.e., linked products) display correctly. However, on the shop/archives pages, the colors do not appear.
Is there a way to display the linked product colors directly in the product cards on the shop/archives pages?
Thank you in advance for your help.
The theme is fast but the support is slow
Hello,
Linked variation does not show the linked swatches on the product grid as a variable product. So if you want to show swatches on the grid, you need to use variation swatches instead of linked from Theme Settings > Shop > variable products > set them as “Grid swatch attribute to display”: https://postimg.cc/FfxThbRd
Best Regards,
I am trying to create a custom solution to display linked products (linked variations) on the archive/shop pages, similar to how they appear on the single product page.
I have a few questions:
1. Storage of linked products:
Could you please clarify how and where Woodmart stores linked products for each product? Are they saved in standard WooCommerce meta fields, or in a custom table / JavaScript configuration?
2. Custom PHP solution:
If I want to create a custom PHP solution to display linked variations on archive/shop pages, what would be the recommended method to fetch this data? Is there a function, meta key, filter, or another approach?
Hello,
Sorry for the misunderstanding.
All values for linked variations are stored in the post meta of a custom post type. For a better understanding of how linked variations are structured and how they work, you can check the code used on the single product page, which is located in the theme file:
inc/integrations/woocommerce/modules/linked-variations/class-frontend.php
Best Regards,