Re: DTD Modularity [Was: Glue RFC]

Joe English <> writes:
> (Murray Altheim) wrote:
>> Is there some type of feature in SGML that allows for document modularity?
>> By that I mean, is there some technical way a compound DTD could be build
>> from pieces in such a manner that we could specify the "Glue RFC" both in
>> terms of an English text and an SGML specification of those pieces, rather
>> than build an entirely new DTD for each glue version? And possibly include
>> within this compound document the current
>> experimental/prototype/standard/(whatever) status of each of its
>> components?
>You can do a lot with parameter entities.  The
>basic idea is to define a set of "hook" entities
>in the core DTD that can be overridden in a wrapper DTD.
>DocBook version 2.3 (just released!) has been reorganized
>into a set of modules, and has hooks for local extensions
>and customizations; see <URL:>.
>I'm sure Terry Allen will be able to provide more details.
>(BTW, Terry, nice job!)
>I've been playing with a design for an extensible HTML DTD;
>work on CoST and my Real Job have been taking up all my
>time of late so I haven't gotten very far with it, but
>if it seems like a worthwhile endeavor I'll try to get
>a draft done and post it here.
>--Joe English


Last night I read over the DocBook 2.3 DTD [1], and as you said, Terry
Allen and Eve Maler have done a terrific job. I'd recommend that those
thinking about future HTML DTD modularity check out the DocBook 2.3 DTDs
(if they haven't already done so), which are set up as a series of cleanly
structured modules. I believe that structurally this would be an
advantageous approach for HTML, especially if some agreed-upon syntax were
developed to state the current status of each module (experimental |
prototype | standard, etc.). Since we are dealing with modules in various
stages of completion, this would seem a necessary feature. I've included
below an attempt at an HTML 2.1 DTD using an approach similar to DocBook
2.3 (please note the disclaimers).

If such a document (or something similar in concept) could be worked into a
functional product, it would save us the headache of waiting for all
component parts to reach maturity and allow "the market" to test features
out with some type of "Glue RFC" as a foundation.

One could, for example, have different HTML driver versions (2.1, 2.2,
etc.) each referencing a different set of modules, modified as necessary as
each module comes to closure. The status of the overall "glue RFC" would be
the status of the least formalized module, the status set similar to Larry
Masinter's `Procedural' vs `Draft Standard' message to the html-wg [2]. For
example, if any included module were labeled "experimental", the composite
glue DTD would be labeled likewise.

Dan, your idea of building the DTD from s-expressions [3] sounds
interesting but very difficult. Have you seen the DocBook DTD that Joe
mentioned? I pulled it apart and found it very understandable. I believe
that the current HTML 2.0 DTD could be modularized without too much
difficulty. I don't know if the process of breaking it into component
modules would invalidate the current draft sent to the IESG, since apart
from SGML file structure the content *should* produce the same end product.

At a point when such a modularization occurs, a scheme such as below could
be used to promote production of working DTDs that would enable developers
to "market test" concepts in various stages of completion. For example,
Amanda Walker could support Netscape's table model with a prototype,
operational DTD, which could be updated when the tables draft becomes a

Joe, I'd love to see what you've done with your "extensible HTML DTD". I'm
not the SGML expert you are, but as an exercise I thought I'd give it a
shot. Please, not too much nitpicking the details: I'm a beginner at this.
The HTMLcore.module could certainly be broken into "submodules" as well.


1) No claim is made here of an accurate or operational DTD.
2) This DTD wishfully pretends that 2.0 is a current ISO standard.
3) Please excuse the fake version numbers and dates.
4) If cornered, I will admit I haven't a clue as to what I'm doing.

------- DTD follows --------

<!-- ---------------------------------------------------------------------- -->
<!--    HTML DTD V2.1
        File: html-21.dtd
        Document Type Definition
        for the HyperText Markup Language plus Tables (HTML DTD Plus Tables)

        $Id: html-21.dtd,v 1.0 1995/09/14 16:50:22 altheim Exp $

        Author: Murray M. Altheim <>

<!ENTITY % HTML.Status

<!ENTITY % HTML.version
        "-//Altheim//DTD HTML 2.1//EN"

        -- Typical usage:

            <!DOCTYPE HTML PUBLIC "-//Altheim//DTD HTML 2.2//EN">

<!ENTITY % ISOlat1.module     "INCLUDE">
<!ENTITY % HTMLcore.module    "INCLUDE">
<!ENTITY % HTMLtables.module  "INCLUDE">

<!-- ---------------------------------------------------------------------- -->
<!-- DTD modules .......................................................... -->

<!-- ISO character entity sets ............................................ -->

<!ENTITY % ISOlat1.Status

<![ %ISOlat1.module; [
"ISO 8879:1986//ENTITIES Added Latin 1//EN//HTML">
<!--end of ISOlat1.module-->]]>

<!-- ...................................................................... -->
<!-- HTML 2.0 DTD
     File: html.dtd
     Document Type Definition for the HyperText Markup Language
     (HTML DTD)
     ISO xxxx:yyyy Standard specification 23-Oct-95

        $Id: html.dtd,v 2.0 1995/09/23 15:30:00 connolly Exp $

        Author: Daniel W. Connolly <>
        See Also: html.decl, html-1.dtd


<!ENTITY % HTMLcore.Status

<!ENTITY % HTMLcore.Version
        "-//IETF//DTD HTML 2.0//EN"

        -- Typical usage:


<![ %HTMLcore.module; [
"-//IETF//DTD HTML 2.0//EN">
<!--end of HTMLcore.module-->]]>

<!-- ...................................................................... -->
<!--    HTML 3.0 Tables v1.0
        File: html3-tables.dtd

        Document Type Definition for HyperText Markup Language Tables
        (HTML Tables DTD)
        Prototype specification 18-Sep-95
        Expires: 18-Mar-96

        $Id: html3-tables.dtd,v 1.0 1995/09/18 12:30:00 raggett Exp $

        Author: Dave Raggett <>
        See Also: html3-tables.dtd


<!ENTITY % HTMLtables.Status

<!ENTITY % HTMLtables.Expires

<!ENTITY % HTMLtables.Version
        "-//IETF//DTD W3C Prototype Spec 18-Sep-95//EN">

<![ %HTMLtables.module; [
"-//IETF//DTD HTML Table Model//EN//HTML">
<!--end of HTMLtables.module-->]]>

<!-- End of HTML DTD V2.1 ................................................. -->
<!-- ---------------------------------------------------------------------- -->

- - - - - - - - - - - - - - - - - - - - - - -
[1] DTD files for DocBook V2.3 available at

     The complete set of DocBook 2.3 files.
     This is the driver file for Version 2.3 of the DocBook DTD.
     This module contains the definitions for table markup
     in DocBook documents.
     Declare and reference any general entities and entity sets here.
     This module contains the definitions for the overall document
     hierarchies of DocBook documents.
     This module contains the definitions for the objects, inline
     elements, and so on that are available to be used as the main
     content of DocBook documents.

[2] Larry Masinter <> (HTML-WG)
    "`Procedural' vs `Draft Standard' for HTML 2.0 extensions?"
    Mon, 11 Sep 95 01:36:39 EDT

[3] Daniel W. Connolly <> (WWW-HTML)
    "Re: DTD Modularity [Was: Glue RFC]"
    Wed, 13 Sep 1995 12:12:28 -0400

      Murray M. Altheim, Information Systems Analyst
      National Technology Transfer Center, Wheeling, West Virginia

Received on Thursday, 14 September 1995 17:04:42 UTC