View Full Version : BODY will not carrry over

04-24-2011, 07:54 PM
I have copied and pasted all of my css coding into a .css file.
I started a new page with with the external style sheet as mentioned above.
<link rel="stylesheet"href="C:\Users\Shepard\Desktop\styles.css" />

Everything works great on the new page except the Body portion. In my style sheet I set left, right, top and bottom margins as well as background-color. When I open my new document it ignors my Body css code? My margins are all ar 0 and my color is white when it should be red.

Any clues?

04-24-2011, 08:09 PM
Post the css.

04-24-2011, 09:21 PM
Your link <link rel="stylesheet"href="C:\Users\Shepard\Desktop\styles.css" /> is referring to a file on your local C:\ drive, is that really the path you want to use? I would expect you really want to link to the styles.css on your server, not the one on your local machine.

See absolute and relative paths explained here (http://www.geeksengine.com/article/absolute-relative-path.html).

That line might also work better with a space betweeen attributes like this
<link rel="stylesheet" href="C:\Users\Shepard\Desktop\styles.css" /> or, even better, something more like this <link href="C:\Users\Shepard\Desktop\styles.css" rel="stylesheet" type="text/css" />

For more help with checking your code see the links about validation in my signature line below.

To see why some of your CSS is being ignored, AndrewGSW is right in asking to see your code - both CSS and HTML would even be better.