How to set a fixed image ratio to product images?

Hello,

I have tried my best after spending countless of days on this topic: making product pictures cover the frame in my collection page

Let me explain: The pictures on my collection template are not covering the whole area for the image. I would like to use 4:3 aspect ratio and make the picture cover or fit all the area dedicated to the product image(object-fit: cover).

I could not find a solution for this after days spent trying my best to figure it out.

So, is there way someone can support me? It would be very kind from you.

Thank you in advance for your guidance and support.

Best regards,

Meriem

hello @Meriem did you tried it by custom coding? or you can also use photoshop to make your product photos to equal size

Hi Sara, I prefer to do it via custom coding. Photoshop is a solution, but not practical for us.

I tried to use object-fit: cover, but it does not work and I do not know why. As I am on mobile, I can’t copy/paste the code of collection-template, but will do it when I log in from a computer.

ok sure i will wait

Hi @Meriem ,

Please send your site and if your site is password protected, please send me the password. I will check it for you.