Background image on Blog posts and pages

Hi Support,

I have combined my blog site with my main site and using Pro theme to manage them now. How do i add a background image to blog posts and pages but not to the rest of the site?

I have this but i cant seem to get the image to display nicely like on the original site. I would like it to be full screen with a parralax effect but currently it just stretches the entire content size and doesnt look great.
body.blog,
body.single-post {
background: url(image url);
background-size: cover;
}

Hi @craig11,

Thanks for reaching out.
You need to set the background-attachment attribute value to fixed to look like the original site. Your CSS code should look like the following.

body.blog, 
body.single-post
{
    background: url(image url);
    background-size: cover;
    background-attachment: fixed;
}

Please remember that the above code will work if copied as it is and doesn’t conflict with any existing style.
Please note that the code provided serves only as a guide to help you get started custom coding on your own if there’s no option offered in our theme or the products we bundle.
We really do not provide support for custom codes that means we can’t fix it in case it conflicts with something on your site nor will we enhance it.

Thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.