Developer forum

Forum » Templates » Images for variantcombinations

Images for variantcombinations

Nikki Strømsnes
Reply
Hello,

I'm working on an eComm solution, in which a product may have one or more variants. Visually, this is shown as small thumbnails, whichs links to the specific variant. The problem is, that I can't figure out how to assign an image to the variant. I've tried setting it in the management center, but this does not output. I contemplated adding another custom field to hold the image, but this does not seem to output either.

The problem may be, that the product is connected to more than one variant (colour and size, e.g. "blue large", "red small").

So far, I've worked around the problem by setting the combination name as the image source, then rebuilding the path with Javascript, but this is a suboptimal solution.

Any ideas?

Replies

 
Nikki Strømsnes
Reply
 
 
Merethe Nielsen
Reply

Hi

I have a testexample. Add the images to each variant in the Media tab for the variants. Check attached screenshots.

To enable differentiation on variants, you need to enable the checkboxes for the Image fields in Management Center (Ecommerce Advenced - Language (in 8.0 the node is called Fields) ) to allow that each variant can have it's own image.

I hope this helps you.

Kind regards,
Merethe
frontend.png ManagementCenter.png variantblue.png variantred.png

 

You must be logged in to post in the forum