1

I have uploaded a ".png" format image for a product at backend and it shows black background at detail page at front.

I want to show it as it is with png format and with no background.

enter image description here

I have tried in etc/view.xml like this :

 <image id="product_page_image_medium" type="image">
     <width>800</width>
     <height>800</height>
     <transparency>true</transparency>
     <background>[255, 255, 255]</background>
  </image>

but not working. Any other suggestion please.

2
  • please run the image resize command and check once Nov 18, 2019 at 6:05
  • you can also set background color of the div in which image is shown...so that transparat color will not display black color
    – Mansi Raja
    Nov 18, 2019 at 6:12

1 Answer 1

0

Please try using one more parameter I.e.

<image id="product_page_image_medium" type="image">
     <width>800</width>
     <height>800</height>
     <frame>false</frame>
     <transparency>false</transparency>
</image>
2
  • thanks for your reply. I have already tried but not working Nov 18, 2019 at 12:13
  • have you use all comands after changes ? Nov 18, 2019 at 12:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.