HTML 4.0 Guidelines for Mobile Access

W3C Note - 15 March 1999

This version:
<http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315>
Latest version:
<http://www.w3.org/TR/NOTE-html40-mobile>
Editors:
Tomihisa Kamada, ACCESS Co.,Ltd. <tomy@access.co.jp>
Takuya Asada, W3C <asada@w3.org>
Masayasu Ishikawa, W3C <mimasa@w3.org>
Shin'ichi Matsui, W3C/Panasonic <matsui@w3.org>

Status of This Document

This document is a Note made available by the World Wide Web Consortium (W3C) for discussion. This document may be updated, replaced or rendered obsolete by other documents at any time. It is inappropriate to use this document as reference material or to cite them as other than "work in progress". This is work in progress, and does not imply endorsement by, or the consensus of, either W3C membership or members of the Mobile Access Interest Group (members only).

This document has been produced as part of the W3C Mobile Access Activity. Please send comments about this document to the public mailing list www-mobile@w3.org (archive).

Abstract

This document describes guidelines for content authors how to create HTML 4.0 contents to be acceptable to mobile devices as much as possible.

Available Formats

This document is available in the following formats:

HTML:
<http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315/NOTE-html40-mobile.html>
A plain text file:
<http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315/NOTE-html40-mobile.txt>
HTML as a gzip'ed tar file, including accompanying resources:
<http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315/NOTE-html40-mobile.tgz>
HTML as a zip file, including accompanying resources:
<http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315/NOTE-html40-mobile.zip>

In case of a discrepancy between the various formats of the document, <http://www.w3.org/TR/1999/NOTE-html40-mobile-19990315> is considered the definitive version.

Table of Contents

  1. Introduction
  2. Requirements from Mobile Access
    1. Hardware Restrictions
    2. Narrow Bandwidth Networking
    3. Accessibility Requirements
  3. Guidelines for Mobile Access
    1. Styles
    2. Scripts, Event Handlers
    3. Forms
    4. Frames
    5. Image Maps
    6. Tables
    7. Objects and Images
    8. Access keys
  4. A Sample HTML 4.0 DTD for Mobile Access
  5. Concluding Remarks and Future Directions

1. Introduction

Ever since the Internet industry exploded a few years ago, numerous related industries have spawned and flourished from the standard WWW (World Wide Web) infrastructure. This growth is most attributable to the exponential growth of Internet users all over the world. Today, Internet access is no longer limited to personal computers and powerful workstations in your office, but is reaching into the your home, as well as on the road.

A new class of electronics devices with Internet access capability called "Information Appliances" was recently born. This Internet access capability is embedded in devices such as televisions, set top boxes, home game machines, telephone-based terminals, PDAs, car navigation systems and cellular phones. These Internet appliances will drive the merger of wireless and wired Internet world that will eventually create a much larger industry than today's predominantly wired Internet industry.

The need to support this new class of information appliances while still meeting the W3C standards and the rigid design requirements are the challenges this evolving industry faces today.

This document describes guidelines for content authors how to use HTML 4.0 Specification [HTML40] effectively for "Mobile Access", and some design notes for user agent manufacturers.

2. Requirements from Mobile Access

There are a wide range of mobile devices in the market. The typical product examples are as follows:

This section summarizes the requirements from "Mobile Access".

2.1. Hardware Restrictions

As described in [CompactHTML], there are several hardware restrictions in mobile devices. The major characteristics are as follows:

These characteristics have to be taken into account in designing the user agent functionality for mobile devices, as well as creating mobile-friendly contents.

2.2. Narrow Bandwidth Networking

The size of contents should be small in the case of narrow bandwidth and low speed wireless networking. The major characteristics of today's wireless connection are as follows:

These restrictions depend on underlying communication bearers. The infrastructure will be improved in the third generation wireless phone networking.

2.3. Accessibility Requirements

Simple and easy operations of information appliances are very important. Unlike PC user interface, keyboard and mouse are not suitable for mobile devices. Rather, intuitive operation like a four-button interface (cursor forward, cursor back, select, and back buttons) is required. In this sense, some kind of accessibility considerations, as described in WAI Accessibility Guidelines, should be taken into account. In general, WAI Accessiblity Guidelines are also useful for mobile access.

For example, the "accesskey" attribute of HTML 4.0 can be used to assign buttons to links or form selections. Also, alternative text for images should be provided via "alt" attribute so that mobile devices can make use of text descriptions instead of large images. For more information, see section 3.8 and 3.7 respectively.

3. Guidelines for Mobile Access

This section describes the detail of the HTML 4.0 guidelines for mobile access.

In order to meet the requirements as described in section 2, we use HTML 4.0 Strict, which excludes the presentation attributes and elements, as a suitable baseline for mobile access. Thus, the following guidelines assume to use HTML 4.0 Strict.

3.1. Styles

Usual mobile devices have small size of screens, and limited display capabilities, thus in many cases style sheets are not supported, or its support is limited.

When style sheets are used, external style sheets are recommended from the viewpoint of content size and separation of structure and style. In this way, user agents which don't support style sheets don't have to load unnecessary style sheets.

The "media" attribute can be used so that user agents can select appropriate style sheets. See section 14.2.4 of [HTML40] for more detail.

The STYLE element can be also used, but inline style sheets via "style" attribute is not preferred, because it's not flexible and almost like the presentation attributes which are deprecated and excluded from the HTML 4.0 Strict.

Contents should be readable without style sheets so that devices which don't support style sheets can still render contents reasonably.

See also section 2.10 of Techniques for [WAI-WEBCONTENT].

Note for User Agents:

It is desirable that even if user agents don't support style sheets, it should parse STYLE elements not to show styles nor to cause any other side-effects.

3.2. Scripts, Event Handlers

Usual mobile devices have limitation of memory storage, CPU power and so on, thus in many cases scripting are not supported. It should not be assumed that scripts will always be executed. Contents should be readable even if scripts are not executed.

See also section 2.13 of Techniques for [WAI-WEBCONTENT].

Note for User Agents:

It is desirable that even if user agents don't support scripts, it should parse SCRIPT elements not to show scripts nor to cause any other side-effects.

3.3. Forms

Usual mobile devices support basic forms, but they don't have keyboards like desktop PCs. Content authors should keep in mind that it will be hard for users of mobile devices to input many characters.

Since sometimes mobile devices don't have local file systems, some features, which depend on local file system, such as file upload, should not be used.

Many mobile devices do not support images, thus value "image" for "type" attribute of INPUT element should not be used.

As described in 3.2, authors should not rely on scripting, and should avoid using attributes for event handling, such as onsubmit.

See also section 2.12 of Techniques for [WAI-WEBCONTENT].

3.4. Frames

Usual mobile devices have small size of screens, and some of them support only textual information. Frames strongly depend on screen interface, and are not part of the HTML 4.0 Strict. Therefore, frames should not be used.

If there is compelling reason to use frames, make sure that those contents have the descriptions below:

See also section 2.11 of Techniques for [WAI-WEBCONTENT].

Note for User Agents:

If user agents don't support frames, it should render contents of the NOFRAMES element. Also, even if user agents can't render frames, it is desirable to provide links to each frame, so that users can access to contents of each frame.

3.5. Image Maps

On mobile devices, it cannot be generally assumed that images are always rendered, nor can be pointed by pointing devices like mouse. Therefore, server-side image maps should not be used.

On the other hand, client-side image maps can be used even if images are not rendered nor can be pointed, so authors may include client-side image maps into their contents. But this is acceptable only when alternative descriptions are provided via "alt" attribute of AREA element, which is a required attribute in HTML 4.0, as in many cases images are not rendered on mobile devices, or pointing on images is impossible even if images can be rendered, as described above.

See also section 2.7 of Techniques for [WAI-WEBCONTENT].

Note for User Agents:

It will be desirable that user agents render images and provide selections with pointing (using area information) if possible. Even if rendering images or selection with pointing are impossible, they should provide access to linked resource of each area via "alt" attribute of AREA element.

3.6. Tables

Many mobile devices have small size of screens. If contents have table descriptions, it will be very difficult to browse them in mobile devices. In addition, though it would be possible to restructure tables in accessible way by following guidelines as described in Guideline 7 of [WAI-WEBCONTENT], it will be difficult for mobile devices to process complex tables due to the hardware restrictions as described in 2.1. It would be, therefore, safe to avoid using tables whenever possible. Consider alternative structures, e.g. lists, whenever appropriate. Content authors should not expect tables will always be processed in mobile devices.

Note for User Agents:

Even if it would be difficult, user agents may parse and render tables if possible. For example, the CAPTION element and "summary" attribute are usable to summarize tables. See also [WAI-USERAGENT].

3.7. Objects and Images

The OBJECT elements, which are designed to embed various objects including images into HTML documents, are also useful in mobile devices. For example, contents which have voice (speech) contents for cell phones and contents which have graphical maps for car navigation systems may become typical contents for those devices, as these contents match essential needs and functions of them.

When embedding objects via OBJECT element, alternative contents should be provided by the fallback mechanism of OBJECT element. These alternative contents should end up with texts.

An example below is quoted from [HTML40]:

  <P>
  <OBJECT data="navbar.png" type="image/png">
    <OBJECT data="navbar.gif" type="image/gif">
      text describing the image...
    </OBJECT>
  </OBJECT>
  </P>

In general, images should be embedded via OBJECT element, as it has better fallback mechanism, but IMG element may also be used. In this case, alternative description via "alt" attribute, which is required in [HTML40], should be provided for user agents which cannot or do not render images. This guideline doesn't specify nor recommend specific formats for images.

If the image represents an important information, a long description should be provided via longdesc attribute of IMG element, in addition to alternative text via alt attribute.

The APPLET element, which is not part of the HTML 4.0 Strict, should not be used in favor of the OBJECT element.

Note for User Agents:

User agents should try to render nested objects according to the precedence rules described in section 13.3.1 of [HTML40]. Even if user agents don't support OBJECT elements, they should render alternative content of OBJECT element as a fallback.

If a long description is provided via longdesc attribute of IMG element, user agents should provide access to that long description.

3.8. Access keys

In general, it cannot be assumed that input methods which consists of a (full) keyboard and a pointing device such as mouse are available in mobile devices. It is desirable that description for efficient use of input methods on mobile devices are provided in contents.

From this viewpoint, assigning access keys via "accesskey" attribute (for A, AREA, BUTTON, INPUT, LABEL, LEGEND and TEXTAREA elements) will be effective when it is available. This may improve accessibility of links or form related operations.

But the use of "accesskey" attribute needs careful consideration.

  1. In many mobile devices, available keys are limited. It cannot be assumed that all keys in "full" keyboards are available.
  2. Available keys differ among mobile devices. For example, cell phones will usually have "0"-"9", "*" and "#" keys, but the same assumption cannot be applied for most pagers or mobile game machines.
  3. There may be some mobile devices that cannot use "accesskey" attribute at all. For example, devices only for voice browsing will not use access "keys". Content authors should not rely on access keys for navigation.

Note for User Agents:

User agents should parse and activate access keys specified via "accesskey" attribute whenever possible, but they should ignore access keys when those keys are not available.

4. A Sample HTML 4.0 DTD for Mobile Access

As mentioned in section 3, HTML 4.0 Strict will be suitable as a baseline for mobile access. This section explains a sample description of DTD, called HTML 4.0 Mobile, as a subset of the HTML 4.0 Strict DTD in order to reflect the guidelines described in section 3.

This DTD is also designed to be a subset of ISO/IEC 15445, a.k.a. ISO-HTML [ISO-HTML]. ISO-HTML is a well-defined subset of HTML 4.0 Strict, so conforming to this DTD will ensure interoperability across wide variety of platforms, including mobile devices. The complete definition of DTD for HTML 4.0 Mobile is described in the Appendix.

Note: At the time of writing this document, [ISO-HTML] is still under work in progress. It has not yet established as an International Standard.

The HTML 4.0 Mobile DTD is provided to help authors creating documents following the guidelines described in this document (e.g. by validating with an SGML parser like nsgmls [SP]). Not all guidelines can be expressed in the DTD, but hopefully, this DTD will make it easier to follow these guidelines.

Typically, this DTD can be invoked as follows:

<!DOCTYPE HTML SYSTEM "html40-mobile.dtd">
<html>
<head>
...

For example, this DTD excludes style attribute and event handlers like onclick, so when content authors validate their documents against this DTD, those attributes will be flagged as unknown attributes and then authors can be aware that those attributes are not recommended. If documents are validated against this DTD, those documents can be labeled as valid HTML 4.0 Strict.

Note. If you use the following DOCTYPE internal subset:

<!DOCTYPE HTML SYSTEM "html40-mobile.dtd" [
<!ENTITY % Preparation "INCLUDE">
]>
<html>
<head>
...

then you can enforce the strict heading order as required in [ISO-HTML].

In any case, ensuring the validity of documents is quite important, particularly for mobile access, because most mobile devices cannot afford to perform costly error recovery.

5. Concluding Remarks and Future Directions

We believe that wireless network services should not be isolated from the growing Internet services. This guidelines can be used for this purpose. It can be referred as recommended guidelines for HTML mobile Internet services and HTML browsing software for a variety of mobile devices.

Currently the work for the next generation of HTML [XHTML] is going on, which will be a family of modularized document types that will make it easier to extend and subset HTML. Since mobile device category is one of major targets for [XHTML], mobile profile(s) and mobile module(s) will be defined as part of [XHTML].

Note that the effort for converging [XHTML] and the Wireless Markup Language [WML], for the Wireless Application Protocol (WAP), is currently ongoing between the W3C and the WAP Forum [WAP-W3C, WML1.1]. Hopefully, [WML] will be among the family of [XHTML] document types in the future.

The worldwide standard for wireless digital phone networking protocols (IMT-2000) will be established very soon. New services based on IMT-2000 standard will start in the early 21st century. The bandwidth of the network is expected to be wide enough for IP connections and Internet-oriented contents.

This implies that HTML and related recommendations for mobile Internet will become more and more important. This HTML 4.0 guidelines for mobile access will be a good step towards future HTML modularity for mobile phones.

References

[CompactHTML]
"Compact HTML for Small Information Appliances", W3C Note, T. Kamada, 9 February 1998.
Available at <http://www.w3.org/TR/1998/NOTE-compactHTML-19980209>
[HTML40]
"HTML 4.0 Specification", W3C Recommendation, D. Raggett, A. Le Hors, I. Jacobs, 18 December 1997, revised 24 April 1998.
Available at <http://www.w3.org/TR/1998/REC-html40-19980424>
"HTML 4.0 Specification Errata" is available at <http://www.w3.org/MarkUp/html40-updates/REC-html40-19980424-errata.html>
[ISO-HTML]
"ISO/IEC 15445:1999 Information Technology -- Document Description and Processing Languages -- HyperText Markup Language (HTML)", R. Price, D. Abrahamson, work in progress.
Available at <http://purl.org/NET/ISO+IEC.15445/15445.html>
See also: "User's Guide to ISO/IEC 15445:1999 HyperText Markup Language (HTML)", available at <http://purl.org/NET/ISO+IEC.15445/Users-Guide.html>
[SP]
SP is a free, object-oriented toolkit for SGML parsing and entity management written by James Clark. Further information is available at <http://www.jclark.com/sp/index.htm>.
[WAI-WEBCONTENT]
"Web Content Accessibility Guidelines", W3C Working Draft, W. Chisholm, G. Vanderheiden, I. Jacobs, work in progress.
See also: "Techniques for Web Content Accessibility Guidelines"
The latest version of these documents can be available from <http://www.w3.org/WAI/#Resources>
[WAI-USERAGENT]
"User Agent Accessibility Guidelines", W3C Working Draft, J. Gunderson, I. Jacobs, work in progress.
The latest version of this document can be available from <http://www.w3.org/WAI/#Resources>
[WAP-W3C]
"WAP Forum - W3C Cooperation White Paper", W3C Note, J. Hjelm, B. Martin, P. King, 30 October 1998.
Available at <http://www.w3.org/TR/NOTE-WAP>
[WML]
"Wireless Markup Language Specification", WAP Forum, 30 April 1998.
Available at <http://www.wapforum.org/docs/technical/wml-30-apr-98.pdf>
[WML1.1]
"Wireless Markup Language Specification Version 1.1", proposed, WAP Forum, 3 February 1999.
Available at <http://www.wapforum.org/docs/technical1.1/WML-3-Feb-1999.pdf>
[XHTML]
"XHTML 1.0: The Extensible HyperText Markup Language - A Reformulation of HTML 4.0 in XML 1.0", W3C Working Draft, Steven Pemberton et al., work in progress.
Available at <http://www.w3.org/TR/WD-html-in-xml>

Appendix HTML 4.0 Mobile DTD

Sample SGML catalog

Note. The HTML 4.0 Mobile DTD is a complete subset of the HTML 4.0 Strict DTD, and if you use the following DTD:

<!ENTITY % HTML.Strict "INCLUDE">
<!ENTITY % Mobile.dtd SYSTEM "html40-mobile.dtd">
%Mobile.dtd;

then you can get the same definition as the HTML 4.0 Strict DTD, as amended by the HTML 4.0 Specification Errata.

The following sample SGML catalog uses the above DTD to invoke the HTML 4.0 Strict DTD. Typically, the Mobile DTD itself will be invoked by a system identifier, so it is not included in this catalog.

  -- HTML 4.0 Strict DTD, as amended by the HTML 4.0 Specification Errata --
PUBLIC "-//W3C//DTD HTML 4.0//EN"                       html40-strict.dtd

  -- entity sets for HTML 4.0 --
PUBLIC "-//W3C//ENTITIES Latin1//EN//HTML"              HTMLlat1.ent
PUBLIC "-//W3C//ENTITIES Special//EN//HTML"             HTMLspecial.ent
PUBLIC "-//W3C//ENTITIES Symbols//EN//HTML"             HTMLsymbol.ent

SGMLDECL html40.decl
DOCTYPE html html40-strict.dtd

Document Type Definition

<!--
    This is HTML 4.0 Mobile DTD, which excludes elements and attributes
    that are difficult to use in mobile devices.

    HTML 4.0 Mobile DTD is designed to be a complete subset of the HTML 4.0
    Strict DTD, and ISO/IEC 15445, a.k.a. ISO-HTML.  ISO-HTML is also
    a subset of the HTML 4.0 Strict DTD.  This DTD takes into account
    the errata for the HTML 4.0 Specification.

      NOTE:  ISO/IEC 15445 is still work in progress.  It is not yet
        an International Standard and it is not appropriate to cite it
        other than as work in progress.

    HTML 4.0 includes mechanisms for style sheets, scripting,
    embedding objects, improved support for right to left and mixed
    direction text, and enhancements to forms for improved
    accessibility for people with disabilities.

          Draft: $ Date: 1999/03/15 03:20:05 $

          Author:
              Masayasu Ishikawa <mimasa@w3.org>

          Authors of the original HTML 4.0 Strict DTD:
              Dave Raggett <dsr@w3.org>
              Arnaud Le Hors <lehors@w3.org>
              Ian Jacobs <ij@w3.org>

    Further information about HTML 4.0 is available at:

        http://www.w3.org/TR/REC-html40
-->
<!--
    Typical usage:

    <!DOCTYPE HTML SYSTEM "html40-mobile.dtd">
    <html>
    <head>
    ...
    </head>
    <body>
    ...
    </body>
    </html>

    As this DTD is intended to be used only for preparing documents,
    FPI for this DTD is not defined.  Use system identifier when you
    invoke this DTD, and the FPI for the Strict DTD should be used
    when you publish the documents conforming to this DTD.

    The FPI for the HTML 4.0 Strict DTD is:

        "-//W3C//DTD HTML 4.0//EN"

    and its URI is:

        http://www.w3.org/TR/REC-html40/strict.dtd

    The following URIs are supported in relation to HTML 4.0.
    These URIs point to the latest version of each file.

    "http://www.w3.org/TR/REC-html40/strict.dtd" (Strict DTD)
    "http://www.w3.org/TR/REC-html40/loose.dtd" (Transitional DTD)
    "http://www.w3.org/TR/REC-html40/frameset.dtd" (Frameset DTD)
    "http://www.w3.org/TR/REC-html40/HTMLlat1.ent" (Latin-1 entities)
    "http://www.w3.org/TR/REC-html40/HTMLsymbol.ent" (Symbol entities)
    "http://www.w3.org/TR/REC-html40/HTMLspecial.ent" (Special entities)

-->

<!-- Feature Switch for Mobile documents -->

<!ENTITY % HTML.Strict "IGNORE">
<![ %HTML.Strict; [
    <!ENTITY % HTML.Mobile "IGNORE">
]]>
<!ENTITY % HTML.Mobile "INCLUDE">

<![ %HTML.Mobile; [
<!-- If the Preparation parameter entity is set to INCLUDE, it allows
     you to enforce the strict heading order, just like the document
     preparation process of ISO-HTML. -->
<!ENTITY % Preparation "IGNORE">

<!-- This definition generates the inverse entity
     NoPreparation which is internal to the DTD. -->
<![ %Preparation; [
<!ENTITY % NoPreparation "IGNORE"    -- Inverse of Preparation = INCLUDE -->
]]>
<!ENTITY % NoPreparation "INCLUDE"   -- Inverse of Preparation = IGNORE -->
]]>

<!-- In ISO-HTML, horizontal tab character is deprecated. -->
<![ %HTML.Mobile; [
<!-- SHORTREF mapping for the tab character -->
<!-- Use of the tab character is deprecated.  However, to facilitate
     the preparation of conforming documents by authors who use it,
     the tab character is tolerated and is mapped into a single space. -->
<!ENTITY   nontab  " " >
<!SHORTREF tabmap  "	" nontab >
<!USEMAP   tabmap  HTML >
]]>

<!--================== Imported Names ====================================-->

<!ENTITY % ContentType "CDATA"
    -- media type, as per [RFC2045]
    -->

<!ENTITY % ContentTypes "CDATA"
    -- comma-separated list of media types, as per [RFC2045]
    -->

<!ENTITY % Charset "CDATA"
    -- a character encoding, as per [RFC2045]
    -->

<!ENTITY % Charsets "CDATA"
    -- a space separated list of character encodings, as per [RFC2045]
    -->

<!ENTITY % LanguageCode "NAME"
    -- a language code, as per [RFC1766]
    -->

<!ENTITY % Character "CDATA"
    -- a single character from [ISO10646]
    -->

<!ENTITY % LinkTypes "CDATA"
    -- space-separated list of link types
    -->

<!ENTITY % MediaDesc "CDATA"
    -- single or comma-separated list of media descriptors
    -->

<!ENTITY % URI "CDATA"
    -- a Uniform Resource Identifier, see [RFC2396]
    -->

<!-- Added to incorporate an erratum for HTML 4.0; taken from [XHTML] -->
<!ENTITY % UriList "CDATA"
    -- a space separated list of Uniform Resource Identifiers
    -->

<![ %HTML.Strict; [
<!ENTITY % Datetime "CDATA" -- date and time information. ISO date format -->

<!ENTITY % Script "CDATA" -- script expression -->
]]>

<!ENTITY % StyleSheet "CDATA" -- style sheet data -->

<!ENTITY % Text "CDATA">

<!-- Parameter Entities -->

<![ %HTML.Strict; [
<!ENTITY % head.misc "SCRIPT|STYLE|META|LINK|OBJECT"
    -- repeatable head elements -->
]]>

<!-- In ISO-HTML, OBJECT is not allowed in HEAD. -->
<!ENTITY % head.misc "STYLE|META|LINK" -- repeatable head elements -->

<!ENTITY % heading "H1|H2|H3|H4|H5|H6">

<!ENTITY % list "UL | OL">

<!ENTITY % preformatted "PRE">


<!--================ Character mnemonic entities =========================-->

<!ENTITY % HTMLlat1 PUBLIC
   "-//W3C//ENTITIES Latin1//EN//HTML"
   "http://www.w3.org/TR/REC-html40/HTMLlat1.ent">
%HTMLlat1;

<!ENTITY % HTMLsymbol PUBLIC
   "-//W3C//ENTITIES Symbols//EN//HTML"
   "http://www.w3.org/TR/REC-html40/HTMLsymbol.ent">
%HTMLsymbol;

<!ENTITY % HTMLspecial PUBLIC
   "-//W3C//ENTITIES Special//EN//HTML"
   "http://www.w3.org/TR/REC-html40/HTMLspecial.ent">
%HTMLspecial;

<!--=================== Generic Attributes ===============================-->

<![ %HTML.Strict; [
<!ENTITY % coreattrs
 "id          ID             #IMPLIED  -- document-wide unique id --
  class       CDATA          #IMPLIED  -- space separated list of classes --
  style       %StyleSheet;   #IMPLIED  -- associated style info --
  title       %Text;         #IMPLIED  -- advisory title/amplification --"
  >
]]>

<!-- Style attribute is excluded from ISO-HTML -->
<!ENTITY % coreattrs
 "id          ID             #IMPLIED  -- document-wide unique id --
  class       CDATA          #IMPLIED  -- space separated list of classes --
  title       %Text;         #IMPLIED  -- advisory title/amplification --"
  >

<!ENTITY % i18n
 "lang        %LanguageCode; #IMPLIED  -- language code --
  dir         (ltr|rtl)      #IMPLIED  -- direction for weak/neutral text --"
  >

<![ %HTML.Strict; [
<!ENTITY % events
 "onclick     %Script;       #IMPLIED  -- a pointer button was clicked --
  ondblclick  %Script;       #IMPLIED  -- a pointer button was double clicked--
  onmousedown %Script;       #IMPLIED  -- a pointer button was pressed down --
  onmouseup   %Script;       #IMPLIED  -- a pointer button was released --
  onmouseover %Script;       #IMPLIED  -- a pointer was moved onto --
  onmousemove %Script;       #IMPLIED  -- a pointer was moved within --
  onmouseout  %Script;       #IMPLIED  -- a pointer was moved away --
  onkeypress  %Script;       #IMPLIED  -- a key was pressed and released --
  onkeydown   %Script;       #IMPLIED  -- a key was pressed down --
  onkeyup     %Script;       #IMPLIED  -- a key was released --"
  >
]]>


<!-- Reserved Feature Switch -->
<!ENTITY % HTML.Reserved "IGNORE">

<!-- The following attributes are reserved for possible future use -->
<![ %HTML.Reserved; [
<!ENTITY % reserved
 "datasrc     %URI;          #IMPLIED  -- a single or tabular Data Source --
  datafld     CDATA          #IMPLIED  -- the property or column name --
  dataformatas (plaintext|html) plaintext -- text or html --"
  >
]]>

<![ %HTML.Strict; [
<!ENTITY % reserved "">

<!ENTITY % attrs "%coreattrs; %i18n; %events;">
]]>

<!ENTITY % attrs "%coreattrs; %i18n;">

<!--=================== Text Markup ======================================-->

<![ %HTML.Strict; [
<!ENTITY % fontstyle
 "TT | I | B | BIG | SMALL">
]]>

<!ENTITY % phrase "EM | STRONG | DFN | CODE |
                   SAMP | KBD | VAR | CITE | ABBR | ACRONYM" >

<![ %HTML.Strict; [
<!ENTITY % special
   "A | IMG | OBJECT | BR | SCRIPT | MAP | Q | SUB | SUP | SPAN | BDO">
]]>

<!ENTITY % special
   "A | IMG | OBJECT | BR | MAP | Q | SPAN | BDO">

<!ENTITY % formctrl "INPUT | SELECT | TEXTAREA | LABEL | BUTTON">

<!-- %inline; covers inline or "text-level" elements -->
<![ %HTML.Strict; [
<!ENTITY % inline "#PCDATA | %fontstyle; | %phrase; | %special; | %formctrl;">
]]>
<!-- In ISO-HTML, form controls can only be appeared in FORM element -->
<!ENTITY % inline "#PCDATA | %phrase; | %special;">

<![ %HTML.Strict; [
<!ELEMENT (%fontstyle;|%phrase;) - - (%inline;)*>
<!ATTLIST (%fontstyle;|%phrase;)
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT (%phrase;) - - (%inline;)+>
<!ATTLIST (%phrase;)
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT (SUB|SUP) - - (%inline;)*    -- subscript, superscript -->
<!ATTLIST (SUB|SUP)
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT SPAN - - (%inline;)*         -- generic language/style container -->
<!ATTLIST SPAN
  %attrs;                              -- %coreattrs, %i18n, %events --
  %reserved;			       -- reserved for possible future use --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT SPAN - - (%inline;)+         -- generic language/style container -->
<!ATTLIST SPAN
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT BDO - - (%inline;)*          -- I18N BiDi over-ride -->
]]>
<![ %HTML.Mobile; [
<!ELEMENT BDO - - (%inline;)+          -- I18N BiDi over-ride -->
]]>
<!ATTLIST BDO
  -- %coreattrs;                          id, class, style, title --
  %coreattrs;                          -- id, class, title --
  lang        %LanguageCode; #IMPLIED  -- language code --
  dir         (ltr|rtl)      #REQUIRED -- directionality --
  >


<!ELEMENT BR - O EMPTY                 -- forced line break -->
<!ATTLIST BR
  -- %coreattrs;                          id, class, style, title --
  %coreattrs;                          -- id, class, title --
  >

<!--================== HTML content models ===============================-->

<!--
    HTML has two basic content models:

        %inline;     character level elements and text strings
        %block;      block-like elements e.g. paragraphs and lists
-->

<![ %HTML.Strict; [
<!ENTITY % block
     "P | %heading; | %list; | %preformatted; | DL | DIV | NOSCRIPT |
      BLOCKQUOTE | FORM | HR | TABLE | FIELDSET | ADDRESS">
]]>

<!-- The content of %block; is changed in accordance with ISO-HTML -->
<!-- FIELDSET is not part of %block; in HTML 4.0 Mobile -->
<!ENTITY % block
     "P | %list; | %preformatted; | DL | DIV |
      BLOCKQUOTE | FORM | HR">

<!ENTITY % flow "%block; | %inline;">

<!-- The following definitions are taken from ISO-HTML -->
<![ %HTML.Mobile; [
<!-- Elements that may appear in a form, section or table -->
<!-- In HTML 4.0 Mobile, FIELDSET is only allowed in a form -->
<!ENTITY % form.content    "(%block; | %inline; | %formctrl; |
                            FIELDSET | ADDRESS)+" >
<!ENTITY % section.content "(%block; | %inline; | ADDRESS)+" >
]]>

<!--=================== Document Body ====================================-->

<![ %HTML.Strict; [
<!ELEMENT BODY O O (%block;|SCRIPT)+ +(INS|DEL) -- document body -->
<!ATTLIST BODY
  %attrs;                              -- %coreattrs, %i18n, %events --
  onload          %Script;   #IMPLIED  -- the document has been loaded --
  onunload        %Script;   #IMPLIED  -- the document has been removed --
  >
]]>

<!-- In ISO-HTML, start tag of BODY element cannot be omitted -->
<![ %HTML.Mobile; [
<!-- The following marked section is for preparation only. -->
<![ %Preparation; [
<!ELEMENT BODY - O ((%block;)*,(H1,DIV1)*) >
]]>
<![ %NoPreparation; [
<!ELEMENT BODY - O (%block;|%heading;)+  -- document body -->
]]>
<!ATTLIST BODY
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT ADDRESS - - (%inline;)* -- information on author -->
<!ATTLIST ADDRESS
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<!-- Content model of ADDRESS element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT ADDRESS - - (%inline;)+ -(IMG|MAP) -- information on author -->
<!ATTLIST ADDRESS
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT DIV - - (%flow;)*            -- generic language/style container -->
<!ATTLIST DIV
  %attrs;                              -- %coreattrs, %i18n, %events --
  %reserved;                           -- reserved for possible future use --
  >
]]>

<!-- Content model of DIV element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT DIV - - %section.content;    -- generic language/style container -->
<!ATTLIST DIV
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--================== The Anchor Element ================================-->

<!ENTITY % Shape "(rect|circle|poly|default)">
<!ENTITY % Coords "CDATA" -- comma separated list of lengths -->

<![ %HTML.Strict; [
<!ELEMENT A - - (%inline;)* -(A)       -- anchor -->
<!ATTLIST A
  %attrs;                              -- %coreattrs, %i18n, %events --
  charset     %Charset;      #IMPLIED  -- char encoding of linked resource --
  type        %ContentType;  #IMPLIED  -- advisory content type --
  name        CDATA          #IMPLIED  -- named link end --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  hreflang    %LanguageCode; #IMPLIED  -- language code --
  rel         %LinkTypes;    #IMPLIED  -- forward link types --
  rev         %LinkTypes;    #IMPLIED  -- reverse link types --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  shape       %Shape;        rect      -- for use with client-side image maps --
  coords      %Coords;       #IMPLIED  -- for use with client-side image maps --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT A - - (%inline;)* -(A)       -- anchor -->
<!ATTLIST A
  %attrs;                              -- %coreattrs, %i18n --
  charset     %Charset;      #IMPLIED  -- char encoding of linked resource --
  type        %ContentType;  #IMPLIED  -- advisory content type --
  name        CDATA          #IMPLIED  -- named link end --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  hreflang    %LanguageCode; #IMPLIED  -- language code --
  rel         %LinkTypes;    #IMPLIED  -- forward link types --
  rev         %LinkTypes;    #IMPLIED  -- reverse link types --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  >
]]>

<!--================== Client-side image maps ============================-->

<!-- These can be placed in the same document or grouped in a
     separate document although this isn't yet widely supported -->

<![ %HTML.Strict; [
<!ELEMENT MAP - - ((%block;)+ | AREA+) -- client-side image map -->
<!ATTLIST MAP
  %attrs;                              -- %coreattrs, %i18n, %events --
  name        CDATA          #REQUIRED -- for reference by usemap --
  >
]]>
<!-- In ISO-HTML, MAP element can only include AREA elements -->
<![ %HTML.Mobile; [
<!ELEMENT MAP - - (AREA)+ -- client-side image map -->
<!ATTLIST MAP
  %attrs;                              -- %coreattrs, %i18n --
  name        CDATA          #REQUIRED -- for reference by usemap --
  >
]]>

<!ELEMENT AREA - O EMPTY               -- client-side image map area -->
<![ %HTML.Strict; [
<!ATTLIST AREA
  %attrs;                              -- %coreattrs, %i18n, %events --
  shape       %Shape;        rect      -- controls interpretation of coords --
  coords      %Coords;       #IMPLIED  -- comma separated list of lengths --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  nohref      (nohref)       #IMPLIED  -- this region has no action --
  alt         %Text;         #REQUIRED -- short description --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST AREA
  %attrs;                              -- %coreattrs, %i18n --
  shape       %Shape;        rect      -- controls interpretation of coords --
  coords      %Coords;       #IMPLIED  -- comma separated list of lengths --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  nohref      (nohref)       #IMPLIED  -- this region has no action --
  alt         %Text;         #REQUIRED -- short description --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<!--================== The LINK Element ==================================-->

<!--
  Relationship values can be used in principle:

   a) for document specific toolbars/menus when used
      with the LINK element in document head e.g.
        start, contents, previous, next, index, end, help
   b) to link to a separate style sheet (rel=stylesheet)
   c) to make a link to a script (rel=script)
   d) by stylesheets to control how collections of
      html nodes are rendered into printed documents
   e) to make a link to a printable version of this document
      e.g. a postscript or pdf version (rel=alternate media=print)
-->

<!ELEMENT LINK - O EMPTY               -- a media-independent link -->
<![ %HTML.Strict; [
<!ATTLIST LINK
  %attrs;                              -- %coreattrs, %i18n, %events --
  charset     %Charset;      #IMPLIED  -- char encoding of linked resource --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  hreflang    %LanguageCode; #IMPLIED  -- language code --
  type        %ContentType;  #IMPLIED  -- advisory content type --
  rel         %LinkTypes;    #IMPLIED  -- forward link types --
  rev         %LinkTypes;    #IMPLIED  -- reverse link types --
  media       %MediaDesc;    #IMPLIED  -- for rendering on these media --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST LINK
  %attrs;                              -- %coreattrs, %i18n --
  charset     %Charset;      #IMPLIED  -- char encoding of linked resource --
  href        %URI;          #IMPLIED  -- URI for linked resource --
  hreflang    %LanguageCode; #IMPLIED  -- language code --
  type        %ContentType;  #IMPLIED  -- advisory content type --
  rel         %LinkTypes;    #IMPLIED  -- forward link types --
  rev         %LinkTypes;    #IMPLIED  -- reverse link types --
  media       %MediaDesc;    #IMPLIED  -- for rendering on these media --
  >
]]>

<!--=================== Images ===========================================-->

<!-- Length defined in strict DTD for cellpadding/cellspacing -->
<![ %HTML.Strict; [
<!ENTITY % Length "CDATA" -- nn for pixels or nn% for percentage length -->
]]>
<!ENTITY % MultiLength "CDATA" -- pixel, percentage, or relative -->

<![ %HTML.Strict; [
<!ENTITY % MultiLengths "CDATA" -- comma-separated list of MultiLength -->

<!ENTITY % Pixels "CDATA" -- integer representing length in pixels -->
]]>

<!-- To avoid problems with text-only UAs as well as
   to make image content understandable and navigable
   to users of non-visual UAs, you need to provide
   a description with ALT, and avoid server-side image maps -->

<!ELEMENT IMG - O EMPTY                -- Embedded image -->
<![ %HTML.Strict; [
<!ATTLIST IMG
  %attrs;                              -- %coreattrs, %i18n, %events --
  src         %URI;          #REQUIRED -- URI of image to embed --
  alt         %Text;         #REQUIRED -- short description --
  longdesc    %URI;          #IMPLIED  -- link to long description
                                          (complements alt) --
  height      %Length;       #IMPLIED  -- override height --
  width       %Length;       #IMPLIED  -- override width --
  usemap      %URI;          #IMPLIED  -- use client-side image map --
  ismap       (ismap)        #IMPLIED  -- use server-side image map --
  >
]]>
<!-- In ISO-HTML, height and width attributes are not supported -->
<![ %HTML.Mobile; [
<!ATTLIST IMG
  %attrs;                              -- %coreattrs, %i18n --
  src         %URI;          #REQUIRED -- URI of image to embed --
  alt         %Text;         #REQUIRED -- short description --
  longdesc    %URI;          #IMPLIED  -- link to long description
                                          (complements alt) --
  usemap      %URI;          #IMPLIED  -- use client-side image map --
  >
]]>

<!-- USEMAP points to a MAP element which may be in this document
  or an external document, although the latter is not widely supported -->

<!--==================== OBJECT ======================================-->
<!--
  OBJECT is used to embed objects as part of HTML pages
  PARAM elements should precede other content. SGML mixed content
  model technicality precludes specifying this formally ...
-->

<![ %HTML.Strict; [
<!ELEMENT OBJECT - - (PARAM | %flow;)*
 -- generic embedded object -->
<!ATTLIST OBJECT
  %attrs;                              -- %coreattrs, %i18n, %events --
  declare     (declare)      #IMPLIED  -- declare but don't instantiate flag --
  classid     %URI;          #IMPLIED  -- identifies an implementation --
  codebase    %URI;          #IMPLIED  -- base URI for classid, data, archive--
  data        %URI;          #IMPLIED  -- reference to object's data --
  type        %ContentType;  #IMPLIED  -- content type for data --
  codetype    %ContentType;  #IMPLIED  -- content type for code --
  archive     %UriList;      #IMPLIED  -- space separated archive list --
  standby     %Text;         #IMPLIED  -- message to show while loading --
  height      %Length;       #IMPLIED  -- override height --
  width       %Length;       #IMPLIED  -- override width --
  usemap      %URI;          #IMPLIED  -- use client-side image map --
  name        CDATA          #IMPLIED  -- submit as part of form --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  %reserved;                           -- reserved for possible future use --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT OBJECT - - (PARAM | %section.content;)*
 -- generic embedded object -->
<!ATTLIST OBJECT
  %attrs;                              -- %coreattrs, %i18n --
  declare     (declare)      #IMPLIED  -- declare but don't instantiate flag --
  classid     %URI;          #IMPLIED  -- identifies an implementation --
  codebase    %URI;          #IMPLIED  -- base URI for classid, data, archive--
  data        %URI;          #IMPLIED  -- reference to object's data --
  type        %ContentType;  #IMPLIED  -- content type for data --
  codetype    %ContentType;  #IMPLIED  -- content type for code --
  standby     %Text;         #IMPLIED  -- message to show while loading --
  usemap      %URI;          #IMPLIED  -- use client-side image map --
  name        CDATA          #IMPLIED  -- submit as part of form --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  >
]]>

<!ELEMENT PARAM - O EMPTY              -- named property value -->
<!ATTLIST PARAM
  id          ID             #IMPLIED  -- document-wide unique id --
  name        CDATA          #REQUIRED -- property name --
  value       CDATA          #IMPLIED  -- property value --
  valuetype   (DATA|REF|OBJECT) DATA   -- How to interpret value --
  type        %ContentType;  #IMPLIED  -- content type for value
                                          when valuetype=ref --
  >

<!--=================== Horizontal Rule ==================================-->
<!-- lang and dir attributes are added to incorporate an erratum
     for HTML 4.0. -->

<!ELEMENT HR - O EMPTY -- horizontal rule -->
<![ %HTML.Strict; [
<!ATTLIST HR
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST HR
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--=================== Paragraphs =======================================-->

<![ %HTML.Strict; [
<!ELEMENT P - O (%inline;)*            -- paragraph -->
<!ATTLIST P
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT P - O (%inline;)+            -- paragraph -->
<!ATTLIST P
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--=================== Headings =========================================-->

<!--
  There are six levels of headings from H1 (the most important)
  to H6 (the least important).
-->

<!--
  ISO-HTML requires very strict heading order. If you want to
  make sure that the document is conforming to this requirement,
  set the Preparation parameter entity to INCLUDE; it allows you
  to enforce the strict heading order by introducing "pseudo"
  elements DIV1 through DIV6.  Those "pseudo" elements shall not
  be appeared in valid HTML 4.0 Strict documents.

  The following comments are normative requirements of ISO-HTML.

  The H1 element shall not be followed by an H3, H4, H5 or H6 element
  without an intervening H2 element.

  The H2 element shall not be followed by an H4, H5 or H6 element
  without an intervening H3 element.

  The H3 element shall not be followed by an H5 or H6 element without
  an intervening H4 element.

  The H4 element shall not be followed by an H6 element without an
  intervening H5 element.

  An H2 element shall be preceded by an H1 element.

  An H3 element shall be preceded by an H2 element.

  An H4 element shall be preceded by an H3 element.

  An H5 element shall be preceded by an H4 element.

  An H6 element shall be preceded by an H5 element.
-->

<![ %HTML.Strict; [
<!ELEMENT (%heading;)  - - (%inline;)* -- heading -->
<!ATTLIST (%heading;)
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT (%heading;)  - - (%inline;)+ -- heading -->
<!-- The following marked section is for preparation only. -->
<![ %Preparation; [
<!ELEMENT DIV1 O O ((%block;)*, (H2,DIV2)* ) >
<!ELEMENT DIV2 O O ((%block;)*, (H3,DIV3)* ) >
<!ELEMENT DIV3 O O ((%block;)*, (H4,DIV4)* ) >
<!ELEMENT DIV4 O O ((%block;)*, (H5,DIV5)* ) >
<!ELEMENT DIV5 O O ((%block;)*, (H6,DIV6)* ) >
<!ELEMENT DIV6 O O ((%block;)*) >
]]>
<!ATTLIST (%heading;)
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--=================== Preformatted Text ================================-->

<!-- excludes markup for images and changes in font size -->
<![ %HTML.Strict; [
<!ENTITY % pre.exclusion "IMG|OBJECT|BIG|SMALL|SUB|SUP">
]]>

<!-- In ISO-HTML, MAP shall not be appeared in PRE element -->
<!ENTITY % pre.exclusion "IMG|OBJECT|MAP">

<![ %HTML.Strict; [
<!ELEMENT PRE - - (%inline;)* -(%pre.exclusion;) -- preformatted text -->
<!ATTLIST PRE
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT PRE - - (%inline;)+ -(%pre.exclusion;) -- preformatted text -->
<!ATTLIST PRE
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--===================== Inline Quotes ==================================-->

<![ %HTML.Strict; [
<!ELEMENT Q - - (%inline;)*            -- short inline quotation -->
<!ATTLIST Q
  %attrs;                              -- %coreattrs, %i18n, %events --
  cite        %URI;          #IMPLIED  -- URI for source document or msg --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT Q - - (%inline;)+            -- short inline quotation -->
<!ATTLIST Q
  %attrs;                              -- %coreattrs, %i18n --
  cite        %URI;          #IMPLIED  -- URI for source document or msg --
  >
]]>

<!--=================== Block-like Quotes ================================-->

<![ %HTML.Strict; [
<!ELEMENT BLOCKQUOTE - - (%block;|SCRIPT)+ -- long quotation -->
<!ATTLIST BLOCKQUOTE
  %attrs;                              -- %coreattrs, %i18n, %events --
  cite        %URI;          #IMPLIED  -- URI for source document or msg --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT BLOCKQUOTE - - (%block;)+ -- long quotation -->
<!ATTLIST BLOCKQUOTE
  %attrs;                              -- %coreattrs, %i18n --
  cite        %URI;          #IMPLIED  -- URI for source document or msg --
  >
]]>

<!--=================== Inserted/Deleted Text ============================-->


<!-- INS/DEL are handled by inclusion on BODY -->
<!-- INS/DEL are not supported in HTML 4.0 Mobile -->
<![ %HTML.Strict; [
<!ELEMENT (INS|DEL) - - (%flow;)*      -- inserted text, deleted text -->
<!ATTLIST (INS|DEL)
  %attrs;                              -- %coreattrs, %i18n, %events --
  cite        %URI;          #IMPLIED  -- info on reason for change --
  datetime    %Datetime;     #IMPLIED  -- date and time of change --
  >
]]>

<!--=================== Lists ============================================-->

<!-- definition lists - DT for term, DD for its definition -->

<!ELEMENT DL - - (DT|DD)+              -- definition list -->
<!ATTLIST DL
  -- %attrs;                              %coreattrs, %i18n, %events --
  %attrs;                              -- %coreattrs, %i18n --
  >

<![ %HTML.Strict; [
<!ELEMENT DT - O (%inline;)*           -- definition term -->
<!ELEMENT DD - O (%flow;)*             -- definition description -->
<!ATTLIST (DT|DD)
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT DT - O (%inline;)+           -- definition term -->
<!ELEMENT DD - O %section.content; -(ADDRESS) -- definition description -->
<!ATTLIST (DT|DD)
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>


<!ELEMENT OL - - (LI)+                 -- ordered list -->
<!ATTLIST OL
  -- %attrs;                              %coreattrs, %i18n, %events --
  %attrs;                              -- %coreattrs, %i18n --
  >

<!-- Unordered Lists (UL) bullet styles -->
<!ELEMENT UL - - (LI)+                 -- unordered list -->
<!ATTLIST UL
  -- %attrs;                              %coreattrs, %i18n, %events --
  %attrs;                              -- %coreattrs, %i18n --
  >


<![ %HTML.Strict; [
<!ELEMENT LI - O (%flow;)*             -- list item -->
<!ATTLIST LI
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<![ %HTML.Mobile; [
<!ELEMENT LI - O (%flow;)+             -- list item -->
<!ATTLIST LI
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<!--================ Forms ===============================================-->
<![ %HTML.Strict; [
<!-- accept is added to incorporate an erratum for HTML 4.0 -->
<!ELEMENT FORM - - (%block;|SCRIPT)+ -(FORM) -- interactive form -->
<!ATTLIST FORM
  %attrs;                              -- %coreattrs, %i18n, %events --
  action      %URI;          #REQUIRED -- server-side form handler --
  method      (GET|POST)     GET       -- HTTP method used to submit the form--
  enctype     %ContentType;  "application/x-www-form-urlencoded"
  onsubmit    %Script;       #IMPLIED  -- the form was submitted --
  onreset     %Script;       #IMPLIED  -- the form was reset --
  accept      %ContentTypes; #IMPLIED  -- list of MIME types for file upload --
  accept-charset %Charsets;  #IMPLIED  -- list of supported charsets --
  >
]]>

<!-- Content model of FORM element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT FORM - - %form.content; -(FORM) -- interactive form -->
<!ATTLIST FORM
  %attrs;                              -- %coreattrs, %i18n --
  action      %URI;          #REQUIRED -- server-side form handler --
  method      (GET|POST)     GET       -- HTTP method used to submit the form--
  enctype     %ContentType;  "application/x-www-form-urlencoded"
  accept-charset %Charsets;  #IMPLIED  -- list of supported charsets --
  >
]]>

<!-- Each label must not contain more than ONE field -->
<![ %HTML.Strict; [
<!ELEMENT LABEL - - (%inline;)* -(LABEL) -- form field label text -->
<!ATTLIST LABEL
  %attrs;                              -- %coreattrs, %i18n, %events --
  for         IDREF          #IMPLIED  -- matches field ID value --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  >
]]>

<!-- Content model of LABEL element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT LABEL - - (%inline;|%formctrl;)+ -(LABEL) -- form field label text -->
<!ATTLIST LABEL
  %attrs;                              -- %coreattrs, %i18n --
  for         IDREF          #IMPLIED  -- matches field ID value --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<![ %HTML.Strict; [
<!ENTITY % InputType
  "(TEXT | PASSWORD | CHECKBOX |
    RADIO | SUBMIT | RESET |
    FILE | HIDDEN | IMAGE | BUTTON)"
   >
]]>

<!-- IMAGE and BUTTON are excluded from ISO-HTML -->
<!-- Form-based file upload is not supported in HTML 4.0 Mobile -->
<!ENTITY % InputType
  "(TEXT | PASSWORD | CHECKBOX |
    RADIO | SUBMIT | RESET |
    HIDDEN)"
   >

<!-- attribute name required for all but submit & reset -->
<!ELEMENT INPUT - O EMPTY              -- form control -->
<![ %HTML.Strict; [
<!ATTLIST INPUT
  %attrs;                              -- %coreattrs, %i18n, %events --
  type        %InputType;    TEXT      -- what kind of widget is needed --
  name        CDATA          #IMPLIED  -- submit as part of form --
  value       CDATA          #IMPLIED  -- required for radio and checkboxes --
  checked     (checked)      #IMPLIED  -- for radio buttons and check boxes --
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  readonly    (readonly)     #IMPLIED  -- for text and passwd --
  size        CDATA          #IMPLIED  -- specific to each type of field --
  maxlength   NUMBER         #IMPLIED  -- max chars for text fields --
  src         %URI;          #IMPLIED  -- for fields with images --
  alt         CDATA          #IMPLIED  -- short description --
  usemap      %URI;          #IMPLIED  -- use client-side image map --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  onselect    %Script;       #IMPLIED  -- some text was selected --
  onchange    %Script;       #IMPLIED  -- the element value was changed --
  accept      %ContentTypes; #IMPLIED  -- list of MIME types for file upload --
  %reserved;                           -- reserved for possible future use --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST INPUT
  %attrs;                              -- %coreattrs, %i18n --
  type        %InputType;    TEXT      -- what kind of widget is needed --
  name        CDATA          #IMPLIED  -- submit as part of form --
  value       CDATA          #IMPLIED  -- required for radio and checkboxes --
  checked     (checked)      #IMPLIED  -- for radio buttons and check boxes --
  size        CDATA          #IMPLIED  -- specific to each type of field --
  maxlength   NUMBER         #IMPLIED  -- max chars for text fields --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<!ELEMENT SELECT - - (OPTGROUP|OPTION)+ -- option selector -->
<![ %HTML.Strict; [
<!ATTLIST SELECT
  %attrs;                              -- %coreattrs, %i18n, %events --
  name        CDATA          #IMPLIED  -- field name --
  size        NUMBER         #IMPLIED  -- rows visible --
  multiple    (multiple)     #IMPLIED  -- default is single selection --
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  onchange    %Script;       #IMPLIED  -- the element value was changed --
  %reserved;                           -- reserved for possible future use --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST SELECT
  %attrs;                              -- %coreattrs, %i18n --
  name        CDATA          #IMPLIED  -- field name --
  size        NUMBER         #IMPLIED  -- rows visible --
  multiple    (multiple)     #IMPLIED  -- default is single selection --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  >
]]>

<!ELEMENT OPTGROUP - - (OPTION)+ -- option group -->
<![ %HTML.Strict; [
<!ATTLIST OPTGROUP
  %attrs;                              -- %coreattrs, %i18n, %events --
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  label       %Text;         #REQUIRED -- for use in hierarchical menus --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST OPTGROUP
  %attrs;                              -- %coreattrs, %i18n --
  label       %Text;         #REQUIRED -- for use in hierarchical menus --
  >
]]>

<!ELEMENT OPTION - O (#PCDATA)         -- selectable choice -->
<![ %HTML.Strict; [
<!ATTLIST OPTION
  %attrs;                              -- %coreattrs, %i18n, %events --
  selected    (selected)     #IMPLIED
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  label       %Text;         #IMPLIED  -- for use in hierarchical menus --
  value       CDATA          #IMPLIED  -- defaults to element content --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST OPTION
  %attrs;                              -- %coreattrs, %i18n --
  selected    (selected)     #IMPLIED
  label       %Text;         #IMPLIED  -- for use in hierarchical menus --
  value       CDATA          #IMPLIED  -- defaults to element content --
  >
]]>

<!ELEMENT TEXTAREA - - (#PCDATA)       -- multi-line text field -->
<![ %HTML.Strict; [
<!ATTLIST TEXTAREA
  %attrs;                              -- %coreattrs, %i18n, %events --
  name        CDATA          #IMPLIED
  rows        NUMBER         #REQUIRED
  cols        NUMBER         #REQUIRED
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  readonly    (readonly)     #IMPLIED
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  onselect    %Script;       #IMPLIED  -- some text was selected --
  onchange    %Script;       #IMPLIED  -- the element value was changed --
  %reserved;                           -- reserved for possible future use --
  >
]]>
<![ %HTML.Mobile; [
<!ATTLIST TEXTAREA
  %attrs;                              -- %coreattrs, %i18n --
  name        CDATA          #IMPLIED
  rows        NUMBER         #REQUIRED
  cols        NUMBER         #REQUIRED
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<!--
  #PCDATA is to solve the mixed content problem,
  per specification only whitespace is allowed there!
 -->
<![ %HTML.Strict; [
<!ELEMENT FIELDSET - - (#PCDATA,LEGEND,(%flow;)*) -- form control group -->
<!ATTLIST FIELDSET
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<!-- Content model of FIELDSET element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT FIELDSET - - (#PCDATA,LEGEND,%form.content;) -(FIELDSET)
                                       -- form control group -->
<!ATTLIST FIELDSET
  %attrs;                              -- %coreattrs, %i18n --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT LEGEND - - (%inline;)*       -- fieldset legend -->
<!ENTITY % LAlign "(top|bottom|left|right)">

<!ATTLIST LEGEND
  %attrs;                              -- %coreattrs, %i18n, %events --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<!-- Content model of LEGEND element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT LEGEND - - (#PCDATA)         -- fieldset legend -->
<!ENTITY % LAlign "(top|bottom|left|right)">

<!ATTLIST LEGEND
  %attrs;                              -- %coreattrs, %i18n --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<![ %HTML.Strict; [
<!ELEMENT BUTTON - -
     (%flow;)* -(A|%formctrl;|FORM|FIELDSET)
     -- push button -->
<!ATTLIST BUTTON
  %attrs;                              -- %coreattrs, %i18n, %events --
  name        CDATA          #IMPLIED
  value       CDATA          #IMPLIED  -- sent to server when submitted --
  type        (button|submit|reset) submit -- for use as form button --
  disabled    (disabled)     #IMPLIED  -- unavailable in this context --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  onfocus     %Script;       #IMPLIED  -- the element got the focus --
  onblur      %Script;       #IMPLIED  -- the element lost the focus --
  %reserved;                           -- reserved for possible future use --
  >
]]>

<!-- Content model of BUTTON element is changed in ISO-HTML -->
<![ %HTML.Mobile; [
<!ELEMENT BUTTON - -
     (%inline;)+ -(A|%formctrl;|FORM|FIELDSET)
     -- push button -->
<!ATTLIST BUTTON
  %attrs;                              -- %coreattrs, %i18n --
  name        CDATA          #IMPLIED
  value       CDATA          #IMPLIED  -- sent to server when submitted --
  type        (submit|reset) submit    -- for use as form button --
  tabindex    NUMBER         #IMPLIED  -- position in tabbing order --
  accesskey   %Character;    #IMPLIED  -- accessibility key character --
  >
]]>

<!--======================= Tables =======================================-->
<!-- Tables are not supported in HTML 4.0 Mobile -->

<!-- IETF HTML table standard, see [RFC1942] -->

<!--
 The BORDER attribute sets the thickness of the frame around the
 table. The default units are screen pixels.

 The FRAME attribute specifies which parts of the frame around
 the table should be rendered. The values are not the same as
 CALS to avoid a name clash with the VALIGN attribute.

 The value "border" is included for backwards compatibility with
 <TABLE BORDER> which yields frame=border and border=implied
 For <TABLE BORDER=1> you get border=1 and frame=implied. In this
 case, it is appropriate to treat this as frame=border for backwards
 compatibility with deployed browsers.
-->
<![ %HTML.Strict; [
<!ENTITY % TFrame "(void|above|below|hsides|lhs|rhs|vsides|box|border)">

<!--
 The RULES attribute defines which rules to draw between cells:

 If RULES is absent then assume:
     "none" if BORDER is absent or BORDER=0 otherwise "all"
-->

<!ENTITY % TRules "(none | groups | rows | cols | all)">

<!-- horizontal placement of table relative to document -->
<!ENTITY % TAlign "(left|center|right)">

<!-- horizontal alignment attributes for cell contents -->
<!ENTITY % cellhalign
  "align      (left|center|right|justify|char) #IMPLIED
   char       %Character;    #IMPLIED  -- alignment char, e.g. char=':' --
   charoff    %Length;       #IMPLIED  -- offset for alignment char --"
  >

<!-- vertical alignment attributes for cell contents -->
<!ENTITY % cellvalign
  "valign     (top|middle|bottom|baseline) #IMPLIED"
  >

<!ELEMENT TABLE - -
     (CAPTION?, (COL*|COLGROUP*), THEAD?, TFOOT?, TBODY+)>
<!ELEMENT CAPTION  - - (%inline;)*     -- table caption -->
<!ELEMENT THEAD    - O (TR)+           -- table header -->
<!ELEMENT TFOOT    - O (TR)+           -- table footer -->
<!ELEMENT TBODY    O O (TR)+           -- table body -->
<!ELEMENT COLGROUP - O (col)*          -- table column group -->
<!ELEMENT COL      - O EMPTY           -- table column -->
<!ELEMENT TR       - O (TH|TD)+        -- table row -->
<!ELEMENT (TH|TD)  - O (%flow;)*       -- table header cell, table data cell-->

<!ATTLIST TABLE                        -- table element --
  %attrs;                              -- %coreattrs, %i18n, %events --
  summary     %Text;         #IMPLIED  -- purpose/structure for speech output--
  width       %Length;       #IMPLIED  -- table width --
  border      %Pixels;       #IMPLIED  -- controls frame width around table --
  frame       %TFrame;       #IMPLIED  -- which parts of frame to render --
  rules       %TRules;       #IMPLIED  -- rulings between rows and cols --
  cellspacing %Length;       #IMPLIED  -- spacing between cells --
  cellpadding %Length;       #IMPLIED  -- spacing within cells --
  %reserved;                           -- reserved for possible future use --
  datapagesize CDATA         #IMPLIED  -- reserved for possible future use --
  >

<!ENTITY % CAlign "(top|bottom|left|right)">

<!ATTLIST CAPTION
  %attrs;                              -- %coreattrs, %i18n, %events --
  >

<!--
COLGROUP groups a set of COL elements. It allows you to group
several semantically related columns together.
-->
<!ATTLIST COLGROUP
  %attrs;                              -- %coreattrs, %i18n, %events --
  span        NUMBER         1         -- default number of columns in group --
  width       %MultiLength;  #IMPLIED  -- default width for enclosed COLs --
  %cellhalign;                         -- horizontal alignment in cells --
  %cellvalign;                         -- vertical alignment in cells --
  >

<!--
 COL elements define the alignment properties for cells in
 one or more columns.

 The WIDTH attribute specifies the width of the columns, e.g.

     width=64        width in screen pixels
     width=0.5*      relative width of 0.5

 The SPAN attribute causes the attributes of one
 COL element to apply to more than one column.
-->
<!ATTLIST COL                          -- column groups and properties --
  %attrs;                              -- %coreattrs, %i18n, %events --
  span        NUMBER         1         -- COL attributes affect N columns --
  width       %MultiLength;  #IMPLIED  -- column width specification --
  %cellhalign;                         -- horizontal alignment in cells --
  %cellvalign;                         -- vertical alignment in cells --
  >

<!--
    Use THEAD to duplicate headers when breaking table
    across page boundaries, or for static headers when
    TBODY sections are rendered in scrolling panel.

    Use TFOOT to duplicate footers when breaking table
    across page boundaries, or for static footers when
    TBODY sections are rendered in scrolling panel.

    Use multiple TBODY sections when rules are needed
    between groups of table rows.
-->
<!ATTLIST (THEAD|TBODY|TFOOT)          -- table section --
  %attrs;                              -- %coreattrs, %i18n, %events --
  %cellhalign;                         -- horizontal alignment in cells --
  %cellvalign;                         -- vertical alignment in cells --
  >

<!ATTLIST TR                           -- table row --
  %attrs;                              -- %coreattrs, %i18n, %events --
  %cellhalign;                         -- horizontal alignment in cells --
  %cellvalign;                         -- vertical alignment in cells --
  >

<!-- Scope is simpler than axes attribute for common tables -->
<!ENTITY % Scope "(row|col|rowgroup|colgroup)">

<!-- TH is for headers, TD for data, but for cells acting as both use TD -->
<!ATTLIST (TH|TD)                      -- header or data cell --
  %attrs;                              -- %coreattrs, %i18n, %events --
  abbr        %Text;         #IMPLIED  -- abbreviation for header cell --
  axis        CDATA          #IMPLIED  -- names groups of related headers--
  headers     IDREFS         #IMPLIED  -- list of id's for header cells --
  scope       %Scope;        #IMPLIED  -- scope covered by header cells --
  rowspan     NUMBER         1         -- number of rows spanned by cell --
  colspan     NUMBER         1         -- number of cols spanned by cell --
  %cellhalign;                         -- horizontal alignment in cells --
  %cellvalign;                         -- vertical alignment in cells --
  >
]]>

<!--================ Document Head =======================================-->
<!-- %head.misc; defined earlier on as "STYLE|META|LINK" -->
<![ %HTML.Strict; [
<!ENTITY % head.content "TITLE & BASE?">
]]>
<!ENTITY % head.content "TITLE">

<![ %HTML.Strict; [
<!ELEMENT HEAD O O (%head.content;) +(%head.misc;) -- document head -->
]]>
<!-- In ISO-HTML, start tag of HEAD element cannot be omitted -->
<![ %HTML.Mobile; [
<!ELEMENT HEAD - O (%head.content;) +(%head.misc;) -- document head -->
]]>
<!ATTLIST HEAD
  %i18n;                               -- lang, dir --
  profile     %URI;          #IMPLIED  -- named dictionary of meta info --
  >

<!-- The TITLE element is not considered part of the flow of text.
       It should be displayed, for example as the page header or
       window title. Exactly one title is required per document.
    -->
<!ELEMENT TITLE - - (#PCDATA) -(%head.misc;) -- document title -->
<!ATTLIST TITLE %i18n;>

<!-- BASE element is excluded from ISO-HTML. -->
<![ %HTML.Strict; [
<!ELEMENT BASE - O EMPTY               -- document base URI -->
<!ATTLIST BASE
  href        %URI;          #REQUIRED -- URI that acts as base URI --
  >
]]>

<!ELEMENT META - O EMPTY               -- generic metainformation -->
<!ATTLIST META
  %i18n;                               -- lang, dir, for use with content --
  http-equiv  NAME           #IMPLIED  -- HTTP response header name  --
  name        NAME           #IMPLIED  -- metainformation name --
  content     CDATA          #REQUIRED -- associated information --
  scheme      CDATA          #IMPLIED  -- select form of content --
  >

<!-- User agents conforming to HTML 4.0 Mobile must avoid showing the
     contents of these element. Otherwise support for them is not required. -->
<!ELEMENT STYLE - - %StyleSheet        -- style info -->
<!ATTLIST STYLE
  %i18n;                               -- lang, dir, for use with title --
  type        %ContentType;  #REQUIRED -- content type of style language --
  media       %MediaDesc;    #IMPLIED  -- designed for use with these media --
  title       %Text;         #IMPLIED  -- advisory title --
  >

<!-- SCRIPT is not supported in ISO-HTML -->
<![ %HTML.Strict; [
<!ELEMENT SCRIPT - - %Script;          -- script statements -->
<!ATTLIST SCRIPT
  charset     %Charset;      #IMPLIED  -- char encoding of linked resource --
  type        %ContentType;  #REQUIRED -- content type of script language --
  src         %URI;          #IMPLIED  -- URI for an external script --
  defer       (defer)        #IMPLIED  -- UA may defer execution of script --
  event       CDATA          #IMPLIED  -- reserved for possible future use --
  for         %URI;          #IMPLIED  -- reserved for possible future use --
  >

<!ELEMENT NOSCRIPT - - (%block;)+
  -- alternate content container for non script-based rendering -->
<!ATTLIST NOSCRIPT
  %attrs;                              -- %coreattrs, %i18n, %events --
  >
]]>

<!--================ Document Structure ==================================-->
<!ENTITY % html.content "HEAD, BODY">

<![ %HTML.Strict; [
<!ELEMENT HTML O O (%html.content;)    -- document root element -->
]]>

<!-- In ISO-HTML, start and end tags of HTML element cannot be omitted -->
<![ %HTML.Mobile; [
<!ELEMENT HTML - - (%html.content;)    -- document root element -->
]]>
<!ATTLIST HTML
  %i18n;                               -- lang, dir --
  >