Jump to content

Fixed Background

Go to solution Solved by tuanphan,

Recommended Posts

Hey people,

 

I am using Code Injection to keep my page background image fixed while the sections move over the top. It is working great on desktop view, but doesn't seem to work on mobile view. Would anyone be able to let me know what I am missing with this... (p.s. I'm not super knowledged with coding. This website was made through self teaching mostly via youtube and Chatgpt. haha)

<style>
  .header, #footer-sections{
    display:none !important;}

#page{
background-image:url(https://images.squarespace-cdn.com/content/6486db2ea9f57144972f519e/ddab9b56-c024-4210-a0f7-8882c5aafb48/Rise+Up+Background.jpeg?content-type=image%2Fjpeg);
background-size: 100%;
  background-attachment:fixed !important;
}

/* Make the page section backgrounds transparent */
#page .page-section {
background: transparent!important
}
#page .page-section .section-background {
background: transparent !important;
}


.section-border{opacity:0!important}
  
</style>

 Any help would be super appreciated.

Link to comment
  • Replies 3
  • Views 1.2k
  • Created
  • Last Reply

Top Posters In This Topic

1 hour ago, Matt_Lifelancs said:

Hey people,

 

I am using Code Injection to keep my page background image fixed while the sections move over the top. It is working great on desktop view, but doesn't seem to work on mobile view. Would anyone be able to let me know what I am missing with this... (p.s. I'm not super knowledged with coding. This website was made through self teaching mostly via youtube and Chatgpt. haha)

<style>
  .header, #footer-sections{
    display:none !important;}

#page{
background-image:url(https://images.squarespace-cdn.com/content/6486db2ea9f57144972f519e/ddab9b56-c024-4210-a0f7-8882c5aafb48/Rise+Up+Background.jpeg?content-type=image%2Fjpeg);
background-size: 100%;
  background-attachment:fixed !important;
}

/* Make the page section backgrounds transparent */
#page .page-section {
background: transparent!important
}
#page .page-section .section-background {
background: transparent !important;
}


.section-border{opacity:0!important}
  
</style>

 Any help would be super appreciated.

What is the website URL?

If my comments are useful, please like and mark my solution as answer. It will encourage me. Thanks

MD Rofik
Website Designer and Digital Marketer

Am I helpful? Want to offer me a coffee?
Send me a message if needed any help. I'll try to reply as soon as possible.


 

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.