Lay Theme Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Search

    Background image opacity

    General Discussion
    2
    2
    255
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      fm last edited by

      Hey everyone,

      I've got my code for my background image:

      body[data-type="page"][data-id="428"] {
      background-image: url();
      background-size: cover;
      background-attachment: fixed;
      }

      but I am struggling with changing the background image opacity. I would still like to keep the menu/site title/text etc that sits on top of the background unaffected by changing the opacity. Any ideas? :)

      1 Reply Last reply Reply Quote 0
      • mariusjopen
        mariusjopen Global Moderator last edited by mariusjopen

        Hi @fm

        if you give the body a background image it will be on the lowest level of your website.
        There is nothing which can be under it. So there is no need to change the opacity of the body. It will affect the whole website.

        Why don't you use the default background image which you can use in the Gridder?

        Otherwise I recommend you to use a custom HTML. Create a div box and use custom CSS to give that box a background:

        background-box {
        background-image: url(YOUR IMAGE URL);
        background-size: cover;
        positiont: fixed;
        width: 100vw;
        height: 100vh;
        }
        

        I hope I could help!

        Best!

        Marius

        www.mariusjopen.world

        1 Reply Last reply Reply Quote 0
        • First post
          Last post

        Before you post

        Use the Search Feature. Maybe there is already a solution to your issue.

        1. Update Lay Theme and all Lay Theme Addons
        2. Disable all Plugins
        3. Go to Lay Options → Custom CSS & HTML, click "Turn Off All Custom Code ", click "Save Changes"
        4. Now see if your problem solved itself
        5. Go here, see if your problem is listed here:
        Troubleshooting

        When you post:
        1. Post a link to where the problem is
        2. If the problem is difficult to explain, post screenshots / link to a video to explain it

        Thanks!

        Online Users

        S
        A
        S
        G
        L
        M

        Recent Topics

        • S

          can't change front page

        • M

          komische boxen auf der Website

        • S

          Theme crashed - because of Polylang?

        laytheme.com