Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1082628
    creativeslime
    Participant

    Hi everyone, I have no scripting knowledge but I really just want to add a transparent, black overlay on images I use as backgrounds in some of my sections. I could do this easily with some other drag and drop style editors but after much searching, and pasting code, I cannot get it to darken.

    I have text over the image so I would like it to darken so I can see the text better.

    #1082940
    Christopher
    Moderator

    Hi there,

    Please add custom class name like transparent-bg to sections that you want to add overlay, please add it in sections class field.

    Add following code in Customize -> Custom -> CSS :

    .transparent-bg{
    position:relative;
    }
    .transparent-bg:before {
        content: "";
        position: absolute;
        top: 0;
        right: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        display: block;
        background-color: rgba(0,0,0,0.5);
    }

    Hope it helps.

  • <script> jQuery(function($){ $("#no-reply-1082628 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>