Site logo

Archived topic

adding sticky above header element and getting icons in alignment

16 replies · Started by racheljohn on June 30, 2021

Viewing posts 1–15 of 17

I am trying to get the above header element I have created to be sticky and trying to get the all top part of this site to look like the original but with just generatepress and generateblocks. I have tried so many different variation and just can't seem to get it to look right.
Live site is: https://www.otteroo.com and dev site in the customer support section

Hi there,

Can you remove the merged header element first?

I don't think it's needed for the layout you are trying to create.

Let me know :)

okay removed it.

okay think I got it removed also I forgot to mention I am trying to get rid of any white space between the Header(picture of kids) and the menu

okay I made a few adjustments and getting closer but still have so much space between the menu and header and can't figure out why.

Hi there,

edit your page, and select the first Container Block, in the Spacing settings reduce/remove the Top Margin which is set to 100px

Ah that's where it was coming from lol. Okay so now I am still trying to make it sticky (so above header element with the menu and logo)

Can you check the URL you provided its now returning a 404 error

the link should be working again now ( we had a power-outage here)

Its not loading still - this time there is no 404 but its just not loading.

okay reset it. hopefully now its working (I did test it and was working now)

Try this CSS:

.sticky-header {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 1000;
}

OR This CSS if you only want it applied to larger screens:

@media(min-width: 769px) {
    .sticky-header {
        position: -webkit-sticky;
        position: sticky;
        top: 0;
        z-index: 1000;
    }
}

That worked great, we are almost there! Now how do I get there to be a strip of white behind the menu when its sticky, the logo and social all have it but the menu doesn't?

This archived topic is closed to new replies.