[Resolved] particular page's background color

Home Forums Support [Resolved] particular page's background color

Home Forums Support particular page's background color

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #206421
    Dmitry Bychenko

    hi, guys

    i need to change particular page’s color.
    this one:
    https://www.dropbox.com/s/sm8lyuxplfw5de5/bckgr_color.jpg?dl=0

    If you install Tom’s plugin Simple CSS you get a window on every page/post under the window we use to put content.
    I use this window to set up page width for a particular page.
    this code:

    .container.grid-container {
    max-width: 900px;
    }

    To change page’s background color i guess the code should be something like:

    .page {
    color: ffffff;
    }

    Guys, what code should be to change particular page’s background color?

    #206446
    Roberto Enrique

    You can target that pages background using the page/post id class that WordPress automatically adds to every page/post

    so you can do something like:

    
    
    body.page-id-[YOUR POST ID]{
        background-color: red;
    }
    
    

    View post on imgur.com

    It should work 🙂

    #206477
    Dmitry Bychenko

    thanks, Roberto!

    i use Simple CSS plugin, it has window for css on every page/post, so i dont really need to know page’s id (which is not a problem to find its id).

    finally i use this code:

    body.page{
    background-color: red;
    }

    dont know, if im right or wrong, but it works.
    thanks!

    #206478
    Tom
    Lead Developer
    Lead Developer

    You can also use Simple CSS: https://wordpress.org/plugins/simple-css/

    It has a metabox for each page/post where you can add your CSS for that page.

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