SGML declaration for XML
ricko at allette.com.au
Wed May 6 16:30:00 BST 1998
From: Stefan Mintert <mintert at irb.informatik.uni-dortmund.de>
>What is the correct SGML declaration for XML?
The correct one is:
<!SGML -- SGML Declaration for XML -- "ISO 8879:1986 (WWW)"
This is the 1997 extensions of SGML for the WWW: character ranges
in names, hexadecimal character references, and white-space handling.
(Parsers in) SGML systems before made before 1998 will not support
<!SGML -- SGML Declaration for XML -- "ISO 8879:1986 (ENR)"
This is the 1996 extension to SGML: it allows character ranges only.
(Parsers in) SGML systems made before 1997 will not support this
XML can still use this: but you will want to use decimal numeric
references only. You must have a DOCTYPE declaration. The parser
must support NET-enabled tag minimization, to cope with <x/> tags,
otherwise just use <x> for EMPTY element types.
"ISO 8879:1986 (ENR)" is transitional only.
Finally <!SGML "ISO 8879:1986"
This is traditional SGML. XML can still use this: but you will want to
decimal numeric character references only, and restrict yourself to
less than 60 name characters more than ASCII. You must have a
DOCTYPE declaration. The parser must support NET-enabled
tag minimization to cope with <x/> tags, otherwise just use <x> for
EMPTY element types.
> a Name may start (NAMESTRT) with a ':'
All uses of ":" are still experimental. Starting a name with ":" would
be done to implement some scoping. In general, XML has avoided anything
which makes parsing or understanding a name depend on context--it has a
terrible complicating effect. (Note however, that attribute and data values
are full of context-dependent connotations.)
My understanding is that the namespace proposal is currently not
intending to allow ":" to prefix names, but you should ask the WG people
for some confirmation: (Tim?)
xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)
More information about the Xml-dev