Jump to content

Change Background Image on mobile : image custom file keep disappearing

Recommended Posts

Site URL: https://helicon-mackerel-9k6a.squarespace.com/

Hello,

I have followed rebecca's tuto to edit all the background image on mobile.

When I do that it seems to work well but the issue I have is that mobile images keep disappearing. The link generated with the custom files for the images to not redirect to an image. It looks like Squarespace remove that image from the custom files.

What should I do to solve that problem?

Here is the code structure I have used for each section where I wanted to show a new image

@media @mobile {
/* Insert Code for Mobile Below This Line*/
  [data-section-id="5f2ab4412795162792d107f8"] {
    img{
      display: none;}

.sqs-block-image img {
display: block;
}
.section-background {
background: url("https://images.squarespace-cdn.com/content/5f2408dcdc63bd117de38332/1601648650311-24MSK5GFD0N999FOUBNF/Artboard+Copy+13.JPG?&content-type=image%2Fjpeg");
background-repeat: no-repeat;
background-size: 100%;
}
}


If you do try to open the link mentioned in the code, you will see that it doesn't work, but I am sure it has worked when I created it.

https://images.squarespace-cdn.com/content/5f2408dcdc63bd117de38332/1601648650311-24MSK5GFD0N999FOUBNF/Artboard+Copy+13.JPG?&content-type=image%2Fjpeg

If someone can help me on that, that would be really great 

Link to comment
  • Replies 2
  • Views 438
  • Created
  • Last Reply

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.