Tiled Css background (Full Version)

All Forums >> [Web Development] >> Cascading Style Sheets



Message


mjmtravel -> Tiled Css background (4/6/2008 9:15:20)

I have a question about a template I'm working on. I want to switch the background color to a image. I have found the background image in the style.css file, but when I make any changes to the images it only changes to a plain white not the image I put in. Here is the original code and here is what I have tried. I'm also not sure where the color on the end is coming from on the end of the original.

Original
body {padding:0; margin:0; color:#000000; background:url(images/bg.gif) repeat-x; background-color:#A8AD9C}

Tried
body{background-image:url('images/sand1.gif');background-repeat: repeat}
body{padding:0; margin:0; color:#000000; background:url('images/sand1.gif');background-repeat: repeat}




Tailslide -> RE: Tiled Css background (4/6/2008 10:01:28)

Should be:

body {padding:0; margin:0; color:#000000; background:#A8AD9C url(images/bg.gif) repeat-x; } 




mjmtravel -> RE: Tiled Css background (4/6/2008 11:47:02)

Thanks but what I'm looking to do is remove the color and replace with a image. The original code works and color is correct but I'm looking to remove the color and replace with images/sand1.gif

Original
body {padding:0; margin:0; color:#000000; background:url(images/bg.gif) repeat-x; background-color:#A8AD9C}




Tailslide -> RE: Tiled Css background (4/6/2008 11:57:52)

What I've given you should show the image repeated throughout the page and if the image isn't available it will show the colour.

Edit: For example: TEST PAGE which uses:

body {background:pink url(flower.gif)  repeat;}


Can you give us a link as it'll be easier to see where the problem is.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.046875