Reposting my question from another forum: I want to add a picture as attribute on product and category page but encountered a problem.
Using Media Image custom attribute type I could not display it on frontend and backend.
After that I use Google and found that the storefront properties in Media Image attribute is bugged and hidden.
Made them visisble, set the image for attribute using aaaand i got the end of image link as text in attribute field in frontend
also i use my code
$attributeName = $_product->getResource()->getAttribute('color_unc');
if ($attributeName) {
$labelValue = $attributeName->getFrontend()->getValue($_product);
$labelName = $attributeName->getFrontend()->getLabel($_product);
}
echo $labelName; echo ' ';echo $labelValue;
in category phtml file and expectedly received the same text
Maybe anyone know how to fix this and get the image instead of text? I will say right away: i want use this for configurable product which have only one color (i can't use swathes for obvious reasons)