Code to fit product images in container

Code to fit product images in container

mischastrive
Tourist
4 0 1

Hello Everyone,

 

We recently migrated our store to Shopify, and our product pictures do not have the same size that Shopify requires.

 

As a result, our images do not fit properly in the container on the product and collection pages.

 

Can someone help me with a code snippet that I can insert to fix this issue?

 

Please see the attached screenshots for clarification.

 

Screenshot 2024-06-28 at 16.38.41.pngScreenshot 2024-06-28 at 16.38.32.png

Replies 6 (6)

ProtoMan44
Shopify Partner
510 43 80

@mischastrive hey, thanks for posting here.
 can you please share the link to inspect it, thanks.

- A thirsty developer passionate about supporting the community. If you'd like to, you can  

Buy me a Coffee.


- Your Shopify Solution Specialist Get a Quote at

ProtoMan44

 - 

Chat On Whatsapp


Crafting exceptional e-commerce experiences to elevate your online presence. Let's build your success story together!
mischastrive
Tourist
4 0 1
ProtoMan44
Shopify Partner
510 43 80

@mischastrive thanks for your response.

there in your theme is a cropping function is running to crop all product images, blow is the proof of a I mage>

original image : https://a19125-9d.myshopify.com/cdn/shop/files/125mm_20blue_bb9b03be-ec95-4413-8859-e14931f44026.jpg

but there code inject it : https://a19125-9d.myshopify.com/cdn/shop/files/125mm_20blue_bb9b03be-ec95-4413-8859-e14931f44026_20x...

please open these 2 links and judge it what I want to say.

- A thirsty developer passionate about supporting the community. If you'd like to, you can  

Buy me a Coffee.


- Your Shopify Solution Specialist Get a Quote at

ProtoMan44

 - 

Chat On Whatsapp


Crafting exceptional e-commerce experiences to elevate your online presence. Let's build your success story together!
mischastrive
Tourist
4 0 1

Yes i see. Is there any way to disable this function? i can't do that manually in the theme. 

BSS-TekLabs
Shopify Partner
683 190 221

Hello.
Our team is ready to help you.
Please share your website address and access password (if necessary) so that we can check and assist you.

If our suggestions are useful, please let us know by giving it a like or marking it as a solution .
For give Gift to customers and Upsell in Cart, check out Salepify: Free Gifts with purchase

Need help from our expert? Kindly share your request with us via community@bsscommerce.com


BSS Commerce - Full-service eCommerce Agency

mischastrive
Tourist
4 0 1