View Full Version : CSS background repeat help

02-09-2012, 07:24 AM
So I've been reading, watching, and listening to tutorials all day, but I've come to a place that I got stumped. I finished the HTML file and started the CSS file.

So, I cut a jpeg from photoshop to repeat the background on the x axis.

I have

<link href="style.css" rel="stylesheet" type="text/css" media="screen" />

in the HTML to refer to the css file style.css

Here is my CSS code

body { font-family: Arial, Helvetica, sans-serif; }

.container {
width: 800px;
margin: 0 auto;

body, div, h1, h2, h3, h4, h5, h6, p, ul, img {margin:0px; padding:0px; }

url (images/background.jpg)

#main {
background-image:url(images/background.jpg) repeat-x;

The Image/Background is not showing up.

The image background.jpg in desktop->webdesignfolder->imagesfolder

The index.html and style.css files are in the desktop->webdesignfolder

Can someone help me out?

02-09-2012, 08:38 AM
Can someone help me out?
have you validated your CSS (http://jigsaw.w3.org/css-validator/)?