Where in the style.css do I put page content colour change options

  • Unknown's avatar

    I’m trying to change the css like this, so I can change specific page or posts content backgrounds only. Not the whole page.. like this from this post, but WHERE in the style.css do I put that code?
    Thanks
    ==============================
    This will allow you to change the background color on the content area site wide (posts and pages).

    #content {
    background: #FFFFFF;
    }
    If you wish to have different colors on different pages, then you would need to use the unique page body class for that individual page. In the example of the About the Idealogue page, it would look like this:

    .page-id-216 #content {
    background: #FFFFFF;
    }
    You can find the unique page body classes for individual pages by visting that page and then viewing the source code (browser view menu) and in the opening body tag, you will see something that starts like this:

    <body class=”page page-id-216…

    The unique page body selector for this particular page is

    page-id-216

    Since it is a css Class, you would precede it in the CSS with a period (.) such as this:

    .page-id-216 #content

  • We cannot directly modify style.css file on WordPress.com.

    CSS can be added to the CSS Editor that is available only if you have the paid Custom Design upgrade on your account.

  • The topic ‘Where in the style.css do I put page content colour change options’ is closed to new replies.