HTML2_X.DTD

Richard Light richard at light.demon.co.uk
Tue Jun 17 18:52:29 BST 1997


Hi,

I'm probably not the only person to have done this, but I had a go at
XML-izing the HTML 2.0 DTD.  Most of the job was straightforward
(although a recent exchange suggests that I would have been better
advised to leave the tag omission rules in as parameter entities!).

However, two issues that remain are the use of '&' in the content model
for <HEAD>, and the liberal use of inclusion and exclusion exceptions.

Both are invalid in XML, and neither can be trivially re-mapped to an
XML-compliant equivalent.  Is anyone else interested in this sort of
issue?  Any thoughts on how these problems should be addressed?  

I don't want to waste bandwidth by copying the whole DTD, but if anyone
wants it, I'll happily forward a copy offline.  Here are the relevant
sections:

1) This is the relevant fragment for the first issue (the '&' content
models have not been changed):

<![ %HTML.Recommended; [
        <!ENTITY % head.extra "">
]]>
<!ENTITY % head.extra "& NEXTID?">

<!ENTITY % head.content "TITLE & ISINDEX? & BASE? %head.extra;">

<!ELEMENT HEAD      (%head.content;)>

2) ... and this goes on to show a couple of the exceptions:

<!-- +(META|LINK) exception removed -->

<!-- <HEAD>     Document head   -->

<!ELEMENT TITLE      (#PCDATA)>
<!-- -(META|LINK) exception removed -->

These are the others (all of them, I think):

<!ENTITY % A.content   "(%heading;|%text;)*">

<!ELEMENT A         %A.content;>
<!-- -(A) exception removed -->

...

<!ELEMENT FORM     %body.content;>
<!-- -(FORM) +(INPUT|SELECT|TEXTAREA) exceptions removed -->

...

<!ELEMENT SELECT     (OPTION+)>
<!-- -(INPUT|SELECT|TEXTAREA) exception removed -->

...

<!ELEMENT TEXTAREA     (#PCDATA)>
<!-- -(INPUT|SELECT|TEXTAREA) exception removed. "*" removed from
content
     model. -->


Richard Light
SGML and Museum Information Consultancy
richard at light.demon.co.uk
3 Midfields Walk 
Burgess Hill
West Sussex RH15 8JA
U.K.
tel. (44) 1444 232067

xml-dev: A list for W3C XML Developers
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To unsubscribe, send to majordomo at ic.ac.uk the following message;
unsubscribe xml-dev
List coordinator, Henry Rzepa (rzepa at ic.ac.uk)




More information about the Xml-dev mailing list