This topic has 10 replies, 3 voices, and was last updated 2 years, 6 months ago ago by Olga Barlow
When I turn variation swatches on, it automatically displays available sizes for each product on the category pages.
I don’t want all the available sizes displayed on my category pages, only the circles for the colour options. I have had to turn variation swatches off temporarily, but how do I change it so that Colour Variations display for each product on category pages and not the sizes?
Hello,
Theme Options > WooCommerce > Shop elements > Variation swatches > Primary Attribute > Color. Then hide sizes using custom CSS code. Enable variation swatches, so we can give you correct code.
Regards
Yes, that is how I done it before but couldn’t understand why sizes showed and not colours.
Okay, I have enabled variation swatches again so please let me know the code to hide the sizes. also, where do I put the code. Thanks.
Hello,
Add the below code to Theme Options > Custom CSS
.content-product .product-details ul.st-swatch-preview[data-attribute="pa_size"] {
display: none;
}
Regards
Hi,
Okay, thanks. I have put the code in Theme Custom CSS – Global CSS, is that correct? It has removed the sizes variations, but the colour variations are still not showing. The swatches are enabled, with primary attribute ‘colour’ but they don’t appear on the category pages. Is there something else I need to change? Thank you.
Hello,
I don’t see that you use swatches for the color attribute https://prnt.sc/wMrQVNQdekTu You use the default select type for that. Edit the attribute and set the color type for that if you want to display that on the shop page.
Regards
Hi,
Thanks, I have done that (choosing color circle) and the colour swatches now show on the category pages – however they are all black, no colours. I have all the colours in ‘attributes’ but they are not showing at all. I wondered if it was because my attribute is spelt colour, not color, but I have the same on my other site and its okay. There must be something else i need to do?
Also, I preferred the dropdown menu for colour choice on the product pages. By choosing to display swatches on the category pages, now I have them also on product pages (also all black circles). Is there a way of keeping the colour swatches on the category pages but still having the dropdown menu for colour choice on the product pages? thanks.
Hello,
You are welcome.
Watch the video tutorial for the variation swatches https://youtu.be/LgzC4iK-j6A
You need to manage every term you have and set the color https://prnt.sc/EKjpsK3OtKu8
Provide us with link to the product where you still have the drop-down for the colors on the single product page.
Regards
Okay, thanks I’ve done it now. I thought that they would already be there because we copied the database from another site. I didn’t realise the colours weren’t copied too.
The dropdown option for colour choices on the product pages have gone since setting up the swatches, so I cannot provide a link to any product with the dropdown menu.
I did prefer the dropdown option so customers could choose colour rather than colour circles (which I only wanted to show on category pages), is there a way to get that back without losing the circle colour swatches on the category pages?
Hello,
Unfortunately, you can’t use the drop-down on the single product page and variation swatches on the category page. Either variation swatches on both or without swatches for the color, sorry.
Regards
You must be logged in to reply to this topic.Log in/Sign up