Jump to content

Help with CSS backgrounds, floating BG parallax effect, BG Breaks Site!! :)

Go to solution Solved by tuanphan,

Recommended Posts

I want to use CSS code to create floating fixed backgrounds like on this website https://briankesinger.com
Like a parallax effect where the content floats over top of the backgrounds.

Here is a test page I setup
https://creativejourney.life/test125

site pass: nga2023
 

Here is the my CSS code that I used so far, however when I try to use more than one background with the effect it breaks the page. I am only able to get one background to function not multiple backgrounds like the page above. Additionally I loose my footer as well, which totally disappears.

//-- Fixed BG Page Test mountains --//
section[data-section-id="632a686e08fe477e2b4ad9d8"]
{
  .section-background {
  background-repeat: no-repeat;
  position: fixed;
  z-index: 0;
  }
}

Any help would be awesome. I really like the look and want to get this to work.
thanks 🙂

Edited by PlasticArcade
Link to comment
  • PlasticArcade changed the title to Help with CSS backgrounds, floating BG parallax effect, BG Breaks Site!! :)
  • Solution

Try this CSS code (for Parallax effect section 2)

[data-section-id="655b0c5f9c28a22da5007305"] {
img {
    visibility: hidden;
}
.section-background {
    background-color: transparent !important;
}
.section-border {
    background-image: url(https://images.squarespace-cdn.com/content/v1/61a2e58f1fd4bc35a51bcb19/1700465777444-YCNPKRVIN0HYQ6D8N157/image-asset.jpeg);
    background-attachment: fixed;
}}

 

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 11/22/2023 at 5:28 PM, PlasticArcade said:

That worked thanks, now there is still the issue of my footer disappearing on pages that use this effect, is there a way to get that back?

What is problem with footer? It already shows to me

image.thumb.png.4c9af4bdf36718aebd7c746a75616831.png

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

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.