HTML and CSS Reference
Notice that the first message in Figure 3.19 indicates that the “backgound-color” property
does not exist. This is a clue to check the syntax of the property name. Edit color.css
and correct the error. Test and revalidate your page. Your browser should now look
similar to the one shown in Figure 3.20 and report only one error.
The error reminds you that FFFFFF is not a color value and expects you to already
know that you need to add a “ # ” character to code a valid color value, #FFFFFF .
Notice how any valid CSS rules are displayed below the error messages. Correct the
color value, save the file, and test again.
Your results should look similar to those shown in Figure 3.21. There are no errors
listed. The Valid CSS Information contains all the CSS style rules in color.css. This
means your file passed the CSS validation test. Congratulations, your color.css file is
valid CSS syntax! It's a good practice to validate your CSS style rules. The CSS valida-
tor can help you to identify code that needs to be corrected quickly and indicate which
style rules a browser is likely to consider valid. Validating CSS is one of the many pro-
ductivity techniques that Web developers commonly use.
The CSS is valid!