Gradient background help please?

Discussion in 'CSS' started by Gatorade, Dec 26, 2006.

  1. #1
    I'm trying to use a gradient image for a background. I want the gradient image to be at the top and then the rest of the page just one color. How is this done? Here's the css code I have for now.

    body {
    	background-image: url(http://www.site.com/images/gb.jpg);
    	background-repeat: repeat-x;
    }
    Code (markup):
    After the image is over the rest of the background is just blank/white. How do I make the rest of the background the color I need?
     
    Gatorade, Dec 26, 2006 IP
  2. Gatorade

    Gatorade Peon

    Messages:
    2,130
    Likes Received:
    222
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Nevermind I figured it out. As soon as I made my post it hit me. Maybe this will be usefull to someone else.

    body {
    	background-image: url(http://www.site.com/images/gb.jpg);
    	background-repeat: repeat-x;
    	background-color: #FFFFFF;
    }
    Code (markup):
    I just needed to throw the background-color: in there to make it work.
     
    Gatorade, Dec 26, 2006 IP