Assignment: Use a tool from the "existing tools" list maintained by the Evaluation and Repair working group on the W3C site to to evaluate or repair at least three web pages -- including one that you've done. Take notes on how easy or hard it is to do.
I was torn between evaluating the Lynx-me tool, the W3C HTML Validator or the CSS Validator. I originally was going to go with the Lynx-me tool because I have not used it before, although I do have a Lynx browser on my Linux box at home so I know what it is like to view pages linearized and text only (not always easy!). But I really feel that we have read over and over how important valid HTML is for accessibility reasons so I decided to go with the HTML Validator, even if I have used it often prior to this class. The CSS Validator is also I tool I use often but to even use this tool your Web page must first be valid HTML.
The tool is an evaluation tool
W3C HTML Validator at Validator.w3.org
The tool is a free service that checks HTML and XHTML documents for conformance to W3C Recommendations and other standards. Because HTML 4.01 and XHTML contains enhancements to ensure accessibility that was not there in previous versions of HTML, I believe Web pages should be marked up using these Document Type Definitions. But, the Validator is used to validate all versions of HTML from HTML 2.0 to XHTML 1.1 and does not check for accessibility DESIGN issues such as fixed table widths or absolute font sizes so the Validator should be used in conjunction with an accessibility Validator like Bobby.
The drawbacks to this tool are that I have found as the HTML standards/recommendations have been developed the Validator often has to catch up thus documents that once validated will no longer do so. Another drawback is that the Validator often puts out error messages that can be confusing. So a person really has to be up-to-date on the standards and the Validator changes as well has having a experience using it and reading the output. I ran into both of these issues when testing pages for this assignment.
The pages I ran through the Validator are:
Since I create my pages by hand using Homesite I have few prompts concerning valid HTML and no accessibility ques. I realize that Homesite does have built in Tag prompts but I have turned those off because I find them annoying and hate when the program starts trying to anticipate my tags and changes what I type.
I like the tool and find it invaluable. Even with an understanding of the HTML/XHTML standards I still make mistakes and the Validator makes it fairly easy to find these errors so I can correct them.
The first page I tested was the Department of Workforce Developments Internet home page. That test came to a quick end with this error message -
Fatal Error: no document type declaration; will parse without validation
I could not parse this document, because it uses a public identifier that is not in my catalog.
You should make the first line of your HTML document a DOCTYPE declaration, for example, for a typical HTML 4.01 document:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<TITLE>Title</TITLE>
</HEAD>
<BODY>
<-- ... body of document ... -->
</BODY>
</HTML>
Since the document only had an HTML tag but no Doctype the Validator could not validate this document. I over-rode the missing Doctype by choosing HTML 4.01 Transitional from the drop-down list and the results were not awful. Here is what it found:
<script language="JavaScript">
^
Error: required attribute "TYPE" not specified
<script language="JavaScript">
^
Error: required attribute "TYPE" not specified
<body bgcolor="#CDE6FF">
^
Error: element "BODY" not allowed here; check which elements this element may be contained within
... "0" src="/images/shim2.gif" width="300" height="3"><br>
^
Error: required attribute "ALT" not specified
Sorry, this document does not validate as HTML 4.01 Transitional.
The second page tested is the home page for a site I did almost two years ago. This site no longer validates because of a lack of character encoding information. The W3C Validator was changed to have improved and expanded Character Encoding support (June 22, 2001) and now it recognizes documents that do not explicitly declare the Character Encoding. Here are the results:
Below are the results of checking this document for XML well-formedness and validity.
No errors found! *
This document would validate as the document type specified if you updated it to match the Options used.
As I was creating this page, I tried to be aware of making it valid XHTML 1.1. After I got done with the text prior to this section, I tested the page to see how well I did. I got zinged on the code that I had cut & pasted from the Validator results. In this copied code I managed to correct all the attributes that did not have quotes around them and the HR tags that did not have the closing slash, but I missed the XHTML requirement for a closing list tag. Below is the output from the Validator; all of this because of missing the closing list item tags. Here is an example of how the Validation results can be confusing. From the error messages you would think a lot more was wrong then just the missing end tags. But sometimes a missing tag has a snowball affect that makes other items below it look wrong when they are not.
Below are the results of checking this document for XML well-formedness and validity.
<li>Line 100, column 29:
^
Error: element "li" not allowed here; possible cause is an inline element containing a block-level element
<li>Line 157, column 23:
^
Error: element "li" not allowed here; possible cause is an inline element containing a block-level element
<li>Line 262, column 50:
^
Error: element "li" not allowed here; possible cause is an inline element containing a block-level element
</ul>
^
Error: end tag for "li" omitted; end tags are required in XML for non-empty elements; empty elements require an end tag or the start tag must end with "/>"
<li>Line 262, column 50:
^
Error: start tag was here
</ul>
^
Error: end tag for "li" omitted; end tags are required in XML for non-empty elements; empty elements require an end tag or the start tag must end with "/>"
<li>Line 157, column 23:
^
Error: start tag was here
</ul>
^
Error: end tag for "li" omitted; end tags are required in XML for non-empty elements; empty elements require an end tag or the start tag must end with "/>"
<li>Line 100, column 29:
^
Error: start tag was here
</ul>
^
Error: end tag for "li" omitted; end tags are required in XML for non-empty elements; empty elements require an end tag or the start tag must end with "/>"
<ul> <li>Line 93, column 29:
^
Error: start tag was here
Sorry, this document does not validate as XHTML 1.1.