Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #561439

    Hi! Is it possible to modify the opacity of the sticky header? thanks!

    #561445

    Hey AirstreamCoach!

    Please choose to display Glassy transparent header and then add following code to Quick CSS in Enfold theme options under General Styling tab

    #header.av_header_glassy {
        background-color: rgba(0,0,0,0.5);
    }

    0,0,0 is RGB value of the color and 0.5 is opacity level

    Best regards,
    Yigit

    #561449

    Hi Yigit! Wow… thanks for your super speedy reply! This works great for altering the opacity of the glassy header but what we are actually looking for is when you scroll and it turns to sticky header (ours goes to solid black) if that opacity can be modified as well? Sorry if my question was unclear. thank you for your help! Jen

    #561454

    Hey!

    My bad :)
    Please use following code in that case

    #header.header-scrolled { background: black; }

    If that does not help, please post the link to your website

    Best regards,
    Yigit

    #561469

    Again, super speedy, thanks! Actually we do already have a solid black sticky header (which appears on scrolling down off the transparent glassy header) but are wondering if that solid black can be modified in opacity. My site url is shared below. THANKS!

    #561686

    Hey!

    Please add following code to Functions.php file in Appearance > Editor

    function transparent_header_scroll(){
    ?>
    <script>
    jQuery(window).scroll(function(){
    if(jQuery(this).scrollTop() > 100) jQuery('#header').addClass('headerbgc');
    if(jQuery(this).scrollTop() < 100) jQuery('#header').removeClass('headerbgc');
    });
    </script>
    <?php
    }
    add_action('wp_footer', 'transparent_header_scroll');

    and then add following code to Quick CSS

    .headerbgc { background: black !important; }

    Best regards,
    Yigit

    #561814

    Excellent. Thank you, very much!

    #562028

    Hi!

    You are welcome, glad we could help!
    Enjoy your weekend!

    Best regards,
    Yigit

    #562108

    Same to you!

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘Sticky Header Opacity’ is closed to new replies.