The basic difference between HTML 3.2 and the new HTML 4.01 is the separation of style from structure. You will notice that many of the presentational features from HTML 3.2 have been "deprecated" -- this means that they have been marked for eventual removal from the standard. In addition, all of the necessary linkages for style sheets have been added (new tags and universal attributes).
The good news is that when authors use HTML to markup a document's structure and style sheets to suggest the document's presentation, they can more easily achieve device-independence. So what's the bad news? Unfortunately, the browsers and the editors don't fully support the standard yet, therefore, most of these new features should be used with care.
The most significant step in HTML 4.01 to improve accessibility is the separation of stylistic presentation from the document structure. When HTML coding focuses on structure, a document is more adaptable to different browsing environments, more easily accommodating large fonts, special colors, speech synthesizers, and Braille tactile feedback devices.
HTML 4.01 also includes many new elements and attributes aimed at improving
the Web's accessibility. The multi-dimensional nature of HTML tables has long
posed problems for non-visual browsing, but new attributes for the <TABLE>
,
<TH>
, and <TD>
elements allow table summaries
and a more explicit association between a cell and its header information. These
attributes give non-visual browsers the ability to render a cell's header information,
possibly in an abbreviated form, before giving the cell's content.
HTML 4.01 also makes forms more accessible adding new tags and attributes.
The <FIELDSET>
tag is used to group form controls together
and the <LEGEND>
element provides a caption for the "fieldset"
group. This grouping process allows users with non-visual browsers to more easily
navigate complex forms. In addition, the new <LABEL>
tag
is used to associate a text label with a form control so that users can more
easily determine what information is required in a given field.
Other accessibility improvements include full image descriptions using the
LONGDESC=
attribute with the <IMG>
tag, alternatives
to images and videos through the <OBJECT>
tag, and alternatives
to image maps through a new content model for the <MAP>
element.
HTML 4.01 has adopted the Universal Character Set as its character set. Previous versions of HTML were restricted to ISO-8859-1, which only handles some western European languages. The Universal Character Set is character-by-character equivalent to Unicode 2.0 and contains characters for almost all languages.
New attributes, LANG=
(language identification) and DIR=
(direction of text/script), can be used with most HTML 4.01 tags (although
they aren't universally supported by the browsers). In addition, the <BDO>
tag allows authors to override the bidirectional algorithm used when right-to-left
text such as Hebrew is presented. HTML 4.01 also offers new special character
entities for easy entry of mathematical symbols, Greek letters, and more.
HTML 4.01 adds tags and attributes for the use of style sheets. Currently, the only universal support among the browsers is for Cascading Style Sheets, version 1 (CSS1), and even so, that support is spotty.
The new ID=
, CLASS=
, and STYLE=
attributes
allow style information to be attached to specific tags. The <LINK>
and <STYLE>
tags have new TYPE=
and MEDIA=
attributes for specifying the style sheet language and output media (screen,
printer, voice, etc.), respectively.
HTML 4.01 has added many enhancements in support of client-side scripting.
The <SCRIPT>
element now includes attributes for specifying
the scripting language, embedding an external script, and deferring execution
of a script. As well, a number of attributes have been added to trigger the
execution of a script after an "event," such as clicking an element,
pressing a key, mouseovers, or changing a value in a form.
Also new in HTML 4.01, the <NOSCRIPT>
element allows for
alternate content for browsers with client-side scripting disabled or not supported.
Although "frames" are a part of the HTML 4.01 standard, the frames model is not changed from the flawed frames model originally proposed by Netscape. Therefore, we continue to discourage the use of frames for Library of Congress pages, unless there is an extremely compelling reason they are needed.
The simple table model of HTML 3.2 is expanded in HTML 4.01 to include row and column groups, greater flexibility in defining a table's rules, and accessibility improvements.
The use of row groups through the <THEAD>, <TFOOT>
,
and <TBODY>
tags, improves the readability of tables by allowing
visual browsers to render static header and footer rows with scrollable body
rows. However, these tags are not yet well supported in the browsers.
The actual HTML 4.01 Tag Set is not significantly different from the previous version (HTML 3.2). Although some new tags have been added, many of them are not supported by the browsers. The most important and currently usable feature of HTML 4.01 is Cascading Style Sheet language.
Although there are 24 new HTML tags in version 4.01, most of these tags are still not supported by Netscape version 4, while many more are supported by Internet Explorer, versions 4 and 5. The new tags in HTML 4.01 are:
<ABBR>
- Indicates a text string as an abbreviation using the TITLE=
attribute to spell out the word. Not currently supported
by any browser.<ACRONYM>
- Indicates a text string as an acronym using the TITLE=
attribute
to spell out the acronym. Supported by IE 4.0 (not Netscape).<BDO>
- Bi-directional text override. Supported by IE 5.0b2 (not
Netscape).<BUTTON>
- Used in forms to create buttons. Supported only by IE 4.0b1
(not Netscape).<COL>
- Used within a <COLGROUP>
(column group) to indicate size
and alignment of individual columns. Supported by IE 3.0a1
(not yet by Netscape).<COLGROUP>
- Acts as a container for groupings of columns in a table. Supported
by IE 3.0a1 (not yet by Netscape).<DEL>
- Indicates content to be deleted. Supported by IE 4.0 (not
by Netscape).<FIELDSET>
- Used to group like fields in a form together. Supported
by IE 4.0b1 (not yet by Netscape).<FRAME>
- Indicates the makeup of a frame within the <FRAMESET>
tag. Supported by Netscape 2.0 and
IE 3.0a1. *<FRAMESET>
- Sets the boundaries of a frame set. Supported
by Netscape 2.0 and IE 3.0a1. *<IFRAME>
- Floating or inline frame. Only supported by IE 3.0b2 and
was originally introduced as IE extension (not supported by Netscape).<INS>
- Used to indicate inserted text (in a document revision). Supported
by IE 4.0 (not by Netscape).<LABEL>
- Used with the ACCESSKEY=
attribute to set a keyboard shortcut
for use with a field in an HTML form. Supported by IE 4.0b2
(not yet by Netscape).<LEGEND>
- Assigns a legend to a <FIELDSET>
grouping in an HTML
form. Supported by IE 4.0b2 (not yet by Netscape).<NOFRAMES>
- Alternative content for browsers that do not supports frames. This must
be used for all <FRAMES>
pages on the Library of Congress.
Supported by Netscape 2.0 and IE 3.0a1
*<NOSCRIPT>
- Contains HTML coded information that will display on browsers that do not
understand the <SCRIPT>
tag. Supported
by Netscape 3.0b5 and IE 3.0<OBJECT>
- This tag was created in order to combine multiple existing tags (and extensions)
for multimedia objects. It would replace <APPLET>
, <EMBED>
,
<BGSOUND>
, <SOUNDS>
and <IMAGE>
tags. Supported by IE 3.0a1 (not yet by Netscape).<OPTGROUP>
- Used for grouping elements in selection lists into hierarchies. Not
currently supported by the standard browsers.<Q>
- An inline element used to denote short quoted sections of text. Supported
by IE 4.0 (not yet by Netscape).<S>
- Same tag as STRIKE, used to denote strike-through text. Supported
by Netscape 3.0b5 and IE 1.0. deprecated
.<SPAN>
- Used to apply style information to a section of text. It is used in-line,
meaning that the text contained inside the SPAN tag continues to flow, without
interruption. Supported by Netscape 4.0b1 and IE 3.0b1.<TBODY>
- Surrounds the "body" of a table in the "Complex Table Model," see <TFOOT>
and <THEAD>
. Supported by IE 4.0 (not
yet by Netscape).<TFOOT>
- Surrounds the "footer" portion of a table in the "Complex Table Model,"
see <TBODY>
and <THEAD>
. Supported
by IE 3.0a1 (not yet by Netscape).<THEAD>
- Surrounds the "header" portion of a table in the "Complex Table Model,"
see <TBODY>
and <TFOOT>
. Supported
by IE 3.0a1 (not yet by Netscape).* Please note: the use of frames on the LC Web site is highly discouraged. Proper frames coding is very complex and hard to manage. In addition, frames can present usability issues for some user communities and can prevent all users from being able to bookmark your pages.
However, there are exceptional cases when some minor use of frames is the best
way to render and present the data. In those cases, it is imperative that a
non-frames version of the information be available (by link) as well as indicated
in the <NOFRAMES>...</NOFRAMES>
container. In addition,
the <!DOCTYPE...>
tag for frame set documents must also be
used.
The tags and attributes listed below are being "deprecated," or gradually phased out, and are followed by a description of the newer tags or techniques replacing them. Although they still may be used with the HTML 4.01 "transitional" DTD, it is still recommended that Library of Congress Web page designers try to stop using in favor of the recommended methods described below.
<ISINDEX>
prompts the user for a single line of input and adds a search interface to the document.
Use the <INPUT>
tag instead.<APPLET>
embeds a Java applet in an HTML document, and is supported by all Java-enabled browsers.
Use <OBJECT>
instead. (Note that <OBJECT>
beat out <EMBED>
as the preferred way to place external elements on an HTML page.)<CENTER>
floats an object in the center of the page. Use style sheets and to align text.<FONT>
and its attributes determine the size, color, and typeface for text.
Use style sheets and font properties instead.<BASEFONT>
sets the base font size using the size=
attribute. Font size changes achieved with the <FONT>
tag are relative to the base font size set by <BASEFONT>
, with a default size of 3. (Note: the W3C draft specifies a default font size of 4, but this is a typographical error.)
Use style sheets instead.<STRIKE>
and <S>
strike through text.
Use style sheets and the text-decoration property instead. <U>
underlines text.
Use style sheets instead.<DIR>
creates multicolumn directory lists.
Use the <UL>
(unordered list) tag instead.<MENU>
creates single-column menu lists.
Use the <UL>
tag instead.Almost all attributes that specify the presentation of an HTML document (e.g., colors, alignment, fonts, graphics, etc.) have been deprecated in favor of style sheets. All attributes of the BODY tag are deprecated in favor of style settings for background, text, link, visited link, active link colors. The following attributes have been deprecated in HTML 4.01.
ALIGN=
<COL>, <COLGROUP>,
<TBODY>, <TD>, <TFOOT>, <TH>, <THEAD>, <TR>
ALINK=
A.ACTIVE
in styles sheets instead.
BACKGROUND=
BGCOLOR=
BORDER=
<IMAGE>
and <OBJECT>
tags. Use style sheets instead.
CLEAR=
<BR>
tag to determine text flow around images.
COLOR=
COMPACT
FACE=
HEIGHT=
HSPACE=
LANGUAGE=
<SCRIPT>
tag to set a predefined scripting language.
LINK=
A.LINK
in style sheets.
NOSHADE
<HR>
tag. Use style sheets instead.
NOWRAP
PROMPT=
<ISINDEX>
to set a prompt. Since <ISINDEX>
is deprecated, so is the PROMPT
attribute.
SIZE=
<HR>, <FONT>
, and <BASEFONT>
tags. Still in use with the forms tags <INPUT>
and <SELECT>
.
START=
<OL>
(ordered lists).
TEXT=
<BODY>
tag. Use style sheets instead.
TYPE=
VALUE=
VERSION=
<!DOCTYPE>
to indicate
HTML version and DTD information.
VLINK=
<BODY>
tag. Set this using style sheets.
VSPACE=
<IMAGE>, <APPLET>
, and <OBJECT>
tags.
WIDTH=
<HR>, <APPLET>, <TD>, <TH>,
and <PRE>
tags. Still in use with the <IFRAME>,< IMAGE>, <OBJECT>, <TABLE>, <COL>,
and <COLGROUP>
tags.
Version 4.01 also officially deletes a few relatively uncommon HTML tags, which could cause problems if the new browsers hew strictly to the 4.01 specification.
<XMP>
, <PLAINTEXT>
, and <LISTING>
all display certain aspects of text placement--such as line breaks and spacing--as they appear in the HTML source document (for example, if you wanted to avoid HTML's automatic wrapping).
Use the <PRE>
tag instead.
CLASS=
ID=
STYLE=
TITLE=
LANG=
DIR=
A number of attributes that define client-side scripting events are common to most elements. The attribute value is a script--typically a function call or a few short statements--that is executed when the event occurs. The value may contain entities (e.g., ").
ONCLICK=
ONDBLCLICK=
ONMOUSEDOWN=
ONMOUSEUP=
ONMOUSEOVER=
ONMOUSEMOVE=
ONMOUSEOUT=
ONKEYPRESS=
ONKEYDOWN=
ONKEYUP=
The HTML 4.01 Full Tag Set is listed below organized by function rather than
alphabetically. For a full description, with examples of tag usage, select the
hypertext link for each individual element. Links take advantage of excellent
existing documentation already on the Web for the Web Design Group's HTMLHelp
site. At the bottom of each entry on that site, a link is provided back to the
World Wide Web Consortium site. Deprecated elements are displayed with the legend
-- deprecated
-- and should be avoided. Use the menu
below to jump quickly to a functional section.
<HTML>
- HTML document
<HEAD>
- Document head<BODY>
- Document body<FRAMESET>
- Frameset<BASE>
- Document base URI<ISINDEX>
- Input prompt deprecated
<LINK>
- Document relationship<META>
- Metadata<SCRIPT>
- Client-side script<STYLE>
- Embedded style sheet<TITLE>
- Document title<ADDRESS>
- Address<BLOCKQUOTE>
- Block quotation<CENTER>
- Centered block deprecated
<DEL>
- Deleted text<DIV>
- Generic block-level container<H1>
- Level-one heading<H2>
- Level-two heading<H3>
- Level-three heading<H4>
- Level-four heading<H5>
- Level-five heading<H6>
- Level-six heading<HR>
- Horizontal rule<INS>
- Inserted text<ISINDEX>
- Input prompt deprecated
<NOSCRIPT>
- Alternate script content<P>
- Paragraph<PRE>
- Preformatted text<DIR>
- Directory list deprecated
<DL>
- Definition list
<LI>
- List itemMENU
- Menu list deprecated
<OL>
- Ordered list<UL>
- Unordered list<TABLE>
- Table
<FORM>
- Interactive form
<BUTTON>
- Button<FIELDSET>
- Form control group
<LEGEND>
- Fieldset caption<INPUT>
- Form input<LABEL>
- Form field label<SELECT>
- Option selector
<OPTGROUP>
- Option group
<OPTION>
- Menu option<TEXTAREA>
- Multi-line text input<A>
- Anchor<APPLET>
- Java applet deprecated
<BASEFONT>
- Base font change deprecated
<BDO>
- BiDi override<BR>
- Line break<FONT>
- Font change deprecated
<IFRAME>
- Inline frame deprecated
<IMG>
- Inline image<MAP>
- Image map
<AREA>
- Image map region<OBJECT>
- Object<PARAM>
- Object parameter<Q>
- Short quotation<SCRIPT>
- Client-side script<SPAN>
- Generic inline container<SUB>
- Subscript<SUP>
- Superscript<ABBR>
- Abbreviation<ACRONYM>
- Acronym<CITE>
- Citation<CODE>
- Computer code<DEL>
- Deleted text<DFN>
- Defined term<EM>
- Emphasis<INS>
- Inserted text<KBD>
- Text to be input<SAMP>
- Sample output<STRONG>
- Strong emphasis<VAR>
- Variable<B>
- Bold text<BIG>
- Large text<I>
- Italic text<S>
- Strike-through text deprecated
<SMALL>
- Small text<STRIKE>
- Strike-through text deprecated
<TT>
- Teletype text<U>
- Underlined text deprecated
<FRAMESET>
- Frameset
<FRAME>
- Frame<NOFRAMES>
- Frames alternate contentMaintained by the Network Development and MARC Standards Office
Links to detailed documentation on Web Design Group site are provided.