Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

E-Commerce Modules /

Discuss about the various e-commerce modules available:
Ecommerce, SS Shop, SilverCart and SwipeStripe
Alternatively, have a look the shared mailinglist.

Moderators: martimiz, Nicolaas, Sean, Ed, frankmullenger, biapar, Willr, Ingo, Jedateach, swaiba

Shop / Silvershop - Detect if a product has a certain variation attribute attached to it.

Go to End



Community Member, 57 Posts

17 January 2017 at 4:22pm

Edited: 17/01/2017 4:23pm

Hey Guys,

I'm a bit stuck on the following:
I'd like to create a function (or use it if it's already there and i've missed it) for returning whether a product has a certain variation attribute attached to it (boolean would be fine). As a simplified example: I have a "size" attribute value type, if a product has an "XL" attribute value allocated to it under "size" in a set variation, I would want the function to return true.

Hopefully someone has got a solution for me - thanks in advance!