HTML and CSS Reference
In-Depth Information
2.9 XHTML Validation
The W3C has a free Markup Validation Service available at that
will validate your XHTML code and check it for syntax errors. XHTML validation
provides students with quick self-assessment—you can prove that your code uses cor-
rect syntax. In the working world, XHTML validation serves as a quality assurance
tool. Invalid code may cause browsers to render the pages slower than otherwise.
In this Hands-On Practice you will use the W3C Markup Validation Service to validate
a Web page. This example uses the design.html page completed in Hands-On Practice
2.8 (student files Chapter2/design.html). Locate design.html and open it in Notepad. We
will add an error to the design.html page. Delete the first closing </li> tag. This modi-
fication should generate several error messages. The first error message will be a direct
result of the incorrect syntax.
Next, attempt to validate the design.html file. Launch a browser and visit the W3C
Markup Validation Service file upload page at
Click the Browse button and select the Chapter2/design.html file from your computer.
Select More Options. Verify that the check boxes next to Show Source and Verbose
Output are checked, as shown in Figure 2.22. Click the Check button to upload the file
to the W3C site.
Figure 2.22
Validate your page
Search WWH ::

Custom Search