Jump to content

How to set different image formats for different store pages

Recommended Posts

On 5/11/2022 at 8:17 PM, BethTheArtist said:

Site URL: https://www.bethanykohrt.com/

Hi there,

I would like to have different image formats for different store pages, meaning all images in one store 1:1 and all images in another store page 4:3. Currently I have to have one format across the whole website.

Any suggestions please?

Thanks in advance!

Beth

You can share link to page where you want to set 4:3, we can take a look

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
On 5/4/2022 at 9:32 AM, sarahcreates said:
On 5/11/2022 at 9:17 AM, BethTheArtist said:

Site URL: https://www.bethanykohrt.com/

Hi there,

I would like to have different image formats for different store pages, meaning all images in one store 1:1 and all images in another store page 4:3. Currently I have to have one format across the whole website.

Any suggestions please?

Thanks in advance!

Beth

If you use Summary Blocks you can adjust the image sizes to what you want but then there are other limitations you might hit with Summary Blocks such as the max products of 30. 

 

Link to comment

Hi @tuanphan yes and it has therefore changed all other stores on my website to the 4:3 ratio. I want almost all of them 1:1 but now and again I need a different ratio (as in this case) and want to be able to change some stores but not all. Hope that makes sense. 

I have had to revert it back to 1:1 as it has messed up all other live stores on my site.

Thanks so much.

Beth

Link to comment
On 5/13/2022 at 1:18 PM, Donna_Vincent said:

 

Thank you - this creates a different layout to all other stores on my site, doesn't it? What I would like is a whole product page set to 4:3 images rather than a separate block within a section and all other store pages set to 1:1 but otherwise identical in layout and design. Unless I have misunderstood. Thanks anyway. B

Link to comment
10 hours ago, BethTheArtist said:

Thank you - this creates a different layout to all other stores on my site, doesn't it? What I would like is a whole product page set to 4:3 images rather than a separate block within a section and all other store pages set to 1:1 but otherwise identical in layout and design. Unless I have misunderstood. Thanks anyway. B

Not necessarily.  It would give you the option to change which store you want the 4:3 photos and then you can show the 1:1 photos for the other stores.   You can customize the summary block and all that you are showing is the title of the painting.  You can duplicate the page that you want the 4:3 photos, add the summary block, set it up with the photo and title to see if it would work for you.

Link to comment
On 5/15/2022 at 8:15 AM, tuanphan said:

Hi,

I see this page already 4:3 ratio?

 

On 5/13/2022 at 1:18 PM, Donna_Vincent said:

 

Hi @creedon Thank you - I have pasted the code into Settings > Advanced > Code Injection > HEADER but it has changed it across the whole site again. I am not sure what I am doing wrong? Thanks so much.

Link to comment
10 hours ago, BethTheArtist said:

I have pasted the code into Settings > Advanced > Code Injection > HEADER but it has changed it across the whole site again.

If you put all the code in that location it will affect the whole site.

You need to follow the second step for each individual Store page you want to change.

Quote

Add code from file change default image aspect ratios for store page.html to Store Settings > Advanced > Page Header Code Injection for the store page.

This is how the store looks before my code runs.

7141461_ScreenShot2022-05-16at1_47_24PM.thumb.png.d1f40f78def2dc3cbad87dc320e5348b.png

And after.

1681575363_ScreenShot2022-05-16at1_47_52PM.thumb.png.32f8681b1a89833371d61a788301b935.png

Let us know how it goes.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment

@creedon Hi there, thanks very much for your reply. I have found the location for each individual store (Store Settings/Advanced/Page Header Code Injection), thank you for that, but I am just not sure which code applies, I thought maybe this one but isn't working? Any help gratefully received! Apologies for total lack of coding basics :-))

      const productsPageAspectRatio = '4:3';
      
      const productDetailPageAspectRatio = '4:3'
Link to comment

The code you posted is not the whole code. You need to following the instructions and install each piece of code where indicated. Then once the code is installed you can set those two lines in the code as you show above. That tells the code what aspect ratio to use.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment

Thanks @creedon, sadly I don't understand what you mean but I thank you for your time anyway. I have read previous posts on the subject and copied and pasted both into the locations described in the link but clearly I haven't done it correctly. I will reach out to Squarespace and see if they can help.

Have a good day.

Beth

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.