Site logo

[Resolved] Content Block Archive Background Color

Home Forums Support [Resolved] Content Block Archive Background Color

Home Forums Support Content Block Archive Background Color

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1923630
    troyw

    Hey guys,

    I’m am trying to change the background colour of my Archive Pages to black. As you will see, I am using Content Block Elements to present the posts, but cannot find how to change the Background Colour of an Archive.
    For example if you look at the links below, the background is White, But I want to change it to Black. If I do this in customizer > Colors > Content it changes the whole website, but I only want to affect the Archives?

    Thanks

    #1923701
    Elvin
    Staff
    Customer Support

    Hi there,

    Are you trying to set it up like this? https://share.getcloudapp.com/v1u0QdEB

    IF yes, try adding this CSS:

    body.archive, body.archive #page {
        background-color: black;
    }
    #1923731
    troyw

    That has worked great on most of the Archive pages Elvin, but hasn’t changed the Blog Archive (News)
    How can I get the /news/ background to change to black as well?

    Thanks

    #1923743
    Elvin
    Staff
    Customer Support

    Let’s modify the selector.

    Try this:

    body.archive, body.archive #page, body.blog, body.blog #page {
        background-color: black;
    }

    I thought “News” page was an archive page when its actually the Blog index page. My bad. 😀

    #1923797
    troyw

    Thanks Elvin, that’s perfect.

    #1923801
    Elvin
    Staff
    Customer Support

    No problem. Glad to be of any help. 😀

    #1938575
    troyw

    Hey team,
    Sorry about this, but I have one more page type that i need to apply the the Black Background too. Its not an Archive it is a post type, so not sure what I would add to the current code to do this.

    #1938588
    Elvin
    Staff
    Customer Support

    Try this CSS:

    body.archive, 
    body.archive #page, 
    body.blog, 
    body.blog #page,
    body.single-label, 
    body.single-label #page {
        background-color: black;
    }
    #1938600
    troyw

    Perfect, thanks Elvin.

    #1938604
    Elvin
    Staff
    Customer Support

    No problem. 😀

Viewing 10 posts - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.