Blog background


#1

Hi there!

I would like to ask how to change the background color using CSS on all posts so the middle part where is the text is white and around the text also the whole sidebar is light grey.

Best Regards

Valter


#2

When I change the color in >customize>colors>sidebar color it won’t change the color under the widgets. Only around the widgets and it looks weird. I would like to have it so the whole right side is in light grey color.


#3

Hello there,

Thank you for asking.

In order to achieve that objective, could you please try to add the following CSS code through the Simple Custom CSS plugin?

.blog,
.blog #secondary,
.blog .page-wrap .content-wrapper,
.archive.category,
.archive.category #secondary,
.archive.category .page-wrap .content-wrapper,
.archive.tag,
.archive.tag #secondary,
.archive.tag .page-wrap .content-wrapper,
.search-results,
.search-results #secondary,
.search-results .page-wrap .content-wrapper,
.single-post,
.single-post #secondary,
.single-post .page-wrap .content-wrapper{
  background: #f7f7f7;
}

.blog #primary,
.single-post #primary,
.archive.tag #primary,
.search-results #primary,
.archive.category #primary{
  background: #fff;
  padding-top: 15px;
}

The code above will be applied to the following pages:

  • Blog index
  • Single blog post
  • Category archive
  • Tag archive
  • Search result

Let me know how it works for you.

Warmest regards,
Kharis