0
votes

Shopify: Product pictures on our collection pages keep changing sizes

Three gurus have been unable to help with a problem our nonprofit store is having. We would be forever grateful if you can.

Pictures on our collection pages keep changing sizes.

We have this problem on Chrome, Safari, and IE. I am on a PC. A colleague here who had never been on the site also had the same problem on multiple browsers on a PC. I spoke with a guru today, who was on a Mac, and he had the same experience. Yes, I refreshed my cache, and that did not help (as we recognized when people who had never been on the site had the same problem).

We are using a modified version of the Supply theme. I cannot imagine any edits to the theme causing this problem.

Please see this collection page of our store, which is in development: https://gfh2.myshopify.com/collections/defenders-of-wildlife (Yes, I know there is no home page. Long story)

Of course, the product pictures should all be the same width. But they are not, and they change from time to time and between browsers.

Sometimes all the pictures are very small, such as you see in this screen grab: https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_1.PNG?6100116406257966738

Sometimes just a few of the pictures appear at the very small size, such as you see in this screen grab: https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_7.PNG?6100116406257966738

If you click to the product pages, the pictures are all the correct size there.

Sometimes some of the pictures appear somewhat smaller than they should (in the range of 70% to 90%, and at least three such smaller sizes, such as you see here: https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_6.PNG?6100116406257966738

Sometimes, if I click a product image on the collection page to go to the product, and then click the Back button to return to the collection page, and do that several times, then the image on the collection page appears at the correct size or at the 70% or 85% size. One time this evening it took three round-trips to do that. Another time it took seven round-trips.

The problem also happens with other collections, such as [Stack Overflow limites how many links I can provide, so just change the collection link provided above to /first-book

When I first loaded that page, just now, all the pics were small. Please see https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_11.PNG?16317572828225077891

I clicked the first one to go to the product page, then Back to the collection page, and made three round trips, and then that one image appeared at the correct size on the collection page. Please see https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_10.PNG?16317572828225077891

I looked at another browser (actions above were in Chrome; I looked at IE), and all the pics there remained small. Refreshing the page 10 times did not help.

Went back to Chrome. Clicked the second picture and clicked back, several round trips. Then the pic on the collection page got larger, but the first pic reverted to small.

Thank you very much!

1

1 Answers

0
votes

Shopify serves images to your pages, by resizing the image file on the server. The intention is to improve page load times, while insuring correct styling for various screen sizes and layouts. Less image files to produce, as well.

To do this, the Shopify server will need more info than just the file name, but the size information as well.

It uses an {image url filter} to include the size data with the image file name.

This is one of your image urls.

https://cdn.shopify.com/s/files/1/2326/7959/files/small_pics_1.PNG?6100116406257966738

The following is an example of an image url that includes the image size. Note the '720x720' between the image name (boat-shoes) and the image format (.jpeg).

https://cdn.shopify.com/s/files/1/1183/1048/products/boat-shoes_720x720.jpeg?v=1459175177

The help section for image url filters states: 'If you don't include an image size, the filter returns a small (100x100) image.' This may explain your issue. Here is the URL of the help section I've referenced.

https://help.shopify.com/en/themes/liquid/filters/url-filters#size-parameters

(If you're used to graphically sizing an image, and then seeing the image at that size on the page, then this would be understandably counter intuitive.)

There are other possibilities. I would need to see the theme code for a more definitive answer. Contact me if I can help.