DOCTYPE misunderstood

Jon Bosak bosak at atlantic-83.Eng.Sun.COM
Thu May 8 23:33:56 BST 1997

[Dave Dawson:]

| From a single source document, marked up in XML, we
| need to produce 4 output transforms, braille, large print, html
| and typeset.

This seems clear enough.

| Additionally, we want (for local use) to be able to 'create'
| 'document type' (our own definition).

Now I'm not quite sure what you're saying.

| Question: Should we be using the doctype as the switch,
| or an input to the output processing application (perhaps as
| a command line option).

An input to the output processing application.

| Our definition on document type goes something along the 
| lines of (for one particular use) - an editors note, a report,
| a memo. [Seems logical to talk about document type in this
| way].

Right.  Note, report, and memo are three different types of documents.
They can be described using three different document type definitions
(DTDs) that list the tags and attributes to be used with each type and
specify structural rules for how they can be used.  This is a fairly
heavy SGML concept that is specified in sections 2.9, 3.2, and 3.3 of
the xml-lang draft but not in a way that anyone would be expected to
understand without quite a bit more explanation.  You don't need to
specify a DTD in XML, and if you don't, you can omit the DOCTYPE line
and just use an XML header.

Since you are trying to coordinate the efforts of multiple authors,
you will eventually have to learn about DTDs, because they are the
primary tool for organizing projects that use XML tagging for
large-scale publishing.  So one of these days you should get a book on
designing SGML DTDs and check out some of the principles.  You will
find that many of the less frequently used DTD constructs have been
left out of XML to make it easier to implement, so you will probably
find the job of learning to construct XML DTDs from an SGML book
rather frustrating, but that's life for early implementors.  By this
time next year we should have some good books on this subject; hang in

In the meantime, you should NOT use doctypes as a way to switch
between output formats from the same source file.  The source file is
conceptually one document type regardless of the output format.

Since we're only about halfway into the larger XML effort, you
presently have a standard way to specify syntax (Part 1, xml-lang) and
a very preliminary standard way to specify hypertext linking (Part 2,
xml-link), but no standard way yet to specify style (that will be Part
3, xml-style) or other output processing.  Some people on this list
are working on Java APIs for XML that would provide one avenue of
standardization, and maybe one of them will jump in at this point and
explain more.

If you want to get a preview of the style language and see some very
simple XML DTDs, check out these examples:

(or .tar.gz).


xml-dev: A list for W3C XML Developers
Archived as:
To unsubscribe, send to majordomo at the following message;
unsubscribe xml-dev
List coordinator, Henry Rzepa (rzepa at

More information about the Xml-dev mailing list