3 Basic document template
Listing 1: | basic template |
1<!
DOCTYPE HTML PUBLIC ”
-//W3C//DTD_HTML_4.01//END”
2”http://www.w3.org/TR/html4/strict.dtd”
>3<HTML lang=”en”
> 4 <HEAD>5 <TITLE>ADA compliant template document
</
TITLE> 6 </
HEAD>7 <BODY>8 <ADDRESS> 9 <A href=mailto:webmaster@some.org
>Webmaster
</
A>10 </
ADDRESS>11 </
BODY>12</
HTML>
According to WebXACT, the HTML document in listing 1 has no errors in all three priority levels. Well, it is not very
surprising, considering the lack of any contents! Nonetheless, there are still elements that we should pay attention
to.
- Line 1 indicates the type of document. Not all HTML documents are the same! In this particular case, the
document is an HTML 4.01 document. For a list and discussion of the various document formats, refer to
http://www.htmlhelp.com/tools/validator/doctype.html
- Line 3 is the usual begin tag of an HTML document. However, it also includes the lang attribute to indicate
the default language used in the document is English. This attribute can help configure a screen reader to use
the right translation dictionary/library.
- Line 5 is really basic, right? Unfortunately, there are documents that miss this really simple tag! A descriptive
title that matches the content can save a reader a lot of frustration.
- Line 8 starts a tag that is optional. However, the element ADDRESS helps to identify this content has to do with
the contact address of the web page creator.