Jump to content

Adding a background colour or image.


Recommended Posts

On the default, to change the background color you need to consider three things

The background, the wrapper (#page) and any padding or margins

so first change the background color in global css to what you want. you can enter white red etc, or use hex so white is #fff;

body {
   background-color: white;
   font-size: 11px;
   font-family: Verdana, Arial, Helvetica, Sans-Serif;
   color: #5d717e;
   text-align:center;
}



Now, if you want the page content to remain on white, separate to the background color, you need to need to change the page div to white by adding a background color like so

/* global layout */
#page {
   width: 980px;
   margin: 0 auto 2px auto;
   text-align:left; background: #fff;
}



What you will notice on the left now is that the elements in the left column such as categories butt up to the background color. So, you might like to add a bit of space, you can do this with padding.

#page {
   width: 980px;
   margin: 0 auto 2px auto;
   text-align:left; background: #fff; padding-left: 10px;



Padding will of course increase the overall width of the page, but as this is just for padding, it should be OK

Hope that helps

Link to comment
Share on other sites

  • 2 years later...

Hello all,

I've been trying to change the background of my theme to an image but all the codes I have tried seem to have no effect and I just see a plain white background.

background: url="http://www.zavidesign.com/shop/themes/basartronic/img/bg.jpg" repeat-x scroll left top #F1F1F1;
font-size: 11px;
font-family: Verdana, Arial, Helvetica, Sans-Serif;
color: #5D717E;
text-align: center;



Any help would be greatly appreciated!

Link to comment
Share on other sites

×
×
  • Create New...