View Full Version : W3C CSS Validator Results


MRiddle
01-25-2006, 11:17 PM
Errors
URI : file://localhost/stylesheet.css

* Line: 10

Parse error - Unrecognized : }
* Line: 25 Context : a:active

Parse Error - [empty string]

Warnings
URI : file://localhost/stylesheet.css

* Line : 2 (Level : 1) You have no color with your background-color : body
* Line : 12 (Level : 1) You have no background-color with your color : a:link
* Line : 17 (Level : 1) You have no background-color with your color : a:visited
* Line : 21 (Level : 1) You have no background-color with your color : a:hover


body {
background-color: #FFFFFF;
background-image: url(wallpaper2.gif);
background-repeat: repeat-x;
}
.style2 {font-family: Arial, Helvetica, sans-serif; font-size: 14px; font-weight: bold; letter-spacing: 1px;}
.style3 {font-family: Arial, Helvetica, sans-serif; font-size: 12px; font-weight: bold; letter-spacing: 1px;}
.style4 {font-family: Arial, Helvetica, sans-serif; font-size: 12px; font-weight: normal; letter-spacing: 0px;}
.style5 {font-family: Arial, Helvetica, sans-serif; font-size: 10px; font-weight: bold; letter-spacing: 0px;}
}
a:link {
color: #3b1108;
text-decoration: none;
}
a:visited {
text-decoration: none;
color: #3b1108;
}
a:hover {
text-decoration: underline;
color: #3b1108;
}
a:active {
text-decoration: none;
color: #3b1108;




Any idea what the errors mean? I'm totally clueless. Thanks so much.

djou
01-26-2006, 01:40 AM
The thing about the bracket } is that you forgot to close it:

a:active {
text-decoration: none;
color: #3b1108;}

As for background colors, it is something that the W3C Validator started mentioning recently. They decided that you should now specify a background color everytime you specify a text color. It however is not necessary for elements that inherit the background color of the body or their containing element. I however recommend you to at least specify the color of the main text, as not everyone has black as their default color.