• Home
  • Blog
  • Showcase
  • Setup Docs
    • Sunshine Help
    • Flex Help
  • Support
    • Support Area
    • Contact us
    • Feedback
  • Connect
    • Newsletter
    • Twitter
    • Facebook
  • My Account
  • Flex
  • Sunshine
Support : Simple Pro Themes

Support : Simple Pro Themes

how to make a white background only on inner post and pages?

If you have purchased a product, please enter the email address that you used to register at time of purchase.
Log In
Lost Password

Create an Account
  • Your username must be unique, and cannot be changed later.
  • We use your email address to email you a secure password and verify your account.

Support › Forums › Sunshine Pro Theme › how to make a white background only on inner post and pages?

  • This topic has 2 replies, 2 voices, and was last updated 4 years, 5 months ago by lindebjerg.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • August 25, 2016 at 8:37 am #1256
    lindebjerg
    Participant

    I would like to get a white (#fff) background on all inner content, all pages and posts. I have this site: http://bayern.lindebjerg.de/ with a small background tile pic, but on all the inner content I would like a white background.

    Something like this:
    background-color: #fff;
    padding: 25px;
    margin-bottom: 25px;

    But how can I make this on only inner content, not on the homepage?

    Best Regards,
    Jesper

    August 25, 2016 at 2:46 pm #1257
    Chinmoy Paul
    Moderator

    Add this PHP script in functions.php file

    add_filter( 'body_class', 'sunshine_add_body_class' );
    function sunshine_add_body_class( $classes ) {
      if( ! is_front_page() ) {
       $classes[] = "inner-page";
      }
      return $classes;
    }

    Now add this CSS in your style.css file

    body.custom-background.inner-page {
      background-image: none!important;
    }
    August 25, 2016 at 5:26 pm #1258
    lindebjerg
    Participant

    Thank you Paul, it rocks;-)

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Log In

Copyright © 2021 · Simple PRO Themes for Genesis Framework · About · FAQs · Contact · Affiliates