adding sidebar background

For discussion and questions related to CMS Specific templates and stylesheets (CSS), and themes. or layout issues. This is not a place for generic "I don't know CSS issues"
Post Reply
wickeddiana
New Member
New Member
Posts: 4
Joined: Sat Jul 05, 2008 7:11 am

adding sidebar background

Post by wickeddiana »

I tried adding a background image to my sidebar but it doesn't seem to work. The image doesn't show up. I am modifying the dafult theme and so far have had everything else look right except for that.

I have been trying to add the code into the sidebar div section. Not sure if there is something else I need to do to make it actually show up.

Can anyone explain how to do this right just in case I am doing something wrong.

Thanks
User avatar
tannos
Forum Members
Forum Members
Posts: 109
Joined: Mon Apr 21, 2008 3:50 pm

Re: adding sidebar background

Post by tannos »

yep
Can you add your CSS otherwise we can't help.
One thing only I know, and that is that I know nothing.
wickeddiana
New Member
New Member
Posts: 4
Joined: Sat Jul 05, 2008 7:11 am

Re: adding sidebar background

Post by wickeddiana »

Sure. Here is the code where I am trying to add my background image.



div#sidebar {
background-image: url (http://moongoddessdesign.com/images/mgd_sidebar.jpg) no-repeat;
background-color:#;
background-position: top; 


  float: left;        /* set sidebar on the left side. Change to right to float it right instead. */
  width: 26%;    /* sidebar width, if you change this please also change #main margins */
  display: inline;  /* FIX IE double margin bug */
  margin-left: 2%;
}


thanks
User avatar
kermit
Power Poster
Power Poster
Posts: 693
Joined: Thu Jan 26, 2006 11:46 am

Re: adding sidebar background

Post by kermit »



works.. (note: i added the matching background color)

and to fill in that background color to bottom of containing div...



Image

if you're gonna write the css longhand...

background-image:url(http://moongoddessdesign.com/images/mgd_sidebar.jpg);
background-color:#d4dadc;
background-position: top;
background-repeat: no-repeat;
Last edited by kermit on Sun Jul 06, 2008 4:04 am, edited 1 time in total.
eternity (n); 1. infinite time, 2. a seemingly long or endless time, 3. the length of time it takes a frozen pizza to cook when you're starving.
4,930,000,000 (n); 1. a very large number, 2. the approximate world population in 1986 when Microsoft Corp issued its IPO. 3. Microsoft's net profit (USD) for the quarter (3 months) ending 31 March 2007.
CMSMS migration and setup services | Hosting with CMSMS installed and ready to go | PM me for Info
wickeddiana
New Member
New Member
Posts: 4
Joined: Sat Jul 05, 2008 7:11 am

Re: adding sidebar background

Post by wickeddiana »

Thanks so much. That definitely worked. :)
Post Reply

Return to “Layout and Design (CSS & HTML)”