[Resolved] Customizing header – sticky

Home Forums Support [Resolved] Customizing header – sticky

Home Forums Support Customizing header – sticky

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #2384111
    Leonardo

    Hey guys,

    I’m customizing with GB my header this way: Elements –> block –> site header. Is it possible to add a sticky effect to entire header?

    #2384145
    David
    Staff
    Customer Support

    Hi there,

    it would require CSS. Can i see the site where this header is ?

    #2384651
    Leonardo

    Hi David,

    i’m training with localwp so unfortunately I can’t share. Anyway, it’s good to know that there isn’t a direct function but it needs css instead. Are there any examples? I looked for them but couldn’t find anything. Thanks

    #2385125
    David
    Staff
    Customer Support

    Ok, so try this:

    1. you block element, i assume it starts with a GB Container Block. Select that – and in Advanced > Additional CSS Class(es) add: sticky-header

    2. Add the following CSS to your site:

    .sticky-header {
        position: sticky;
        top: 0;  
    }
    #2385260
    Leonardo

    It works perfectly! Thanks David

    #2385306
    David
    Staff
    Customer Support
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.