Re: end tags...

Murray Altheim (
Sun, 22 Sep 1996 17:55:29 -0500

Message-Id: <v02110105ae6b70a570db@[]>
Date: Sun, 22 Sep 1996 17:55:29 -0500
To: "Carl Morris" <>
From: (Murray Altheim)
Subject: Re: end tags...

Carl Morris <> writes:
>|     <!ENTITY % heading "H1|H2|H3|H4|H5|H6">
>| [...]
>|     <!ELEMENT ( %heading )  - -  (%text;)*>
>| Big difference. The "- -" in H1-H6 means both start and end tags are
>|     <!ELEMENT P     - O (%text)*>
>| The "- O" in P means the end tag is optional. Arnoud is correct: the
>| element requires an end tag, so the given example is invalid.
>See, I told people this DTD is "crap"... whats wrong wiuth REQUIRED or
>OPTIONAL, no, they using numbers ... just to make sure little people
>like me won't learn it...

You really need to get a handle on your anger -- there is no conspiracy. In
previous messages you've mentioned you understand programming languages.
Try leaving a semicolon off of the end of a C statement. The particular
syntax of a DTD is no more arcane than C or SmallTalk or Lisp or HyperTalk
-- it's just different. I learned DTD syntax in about a month, and I'm no

>So do you advise browsers to throw a tantraum or to be intellegent and
>bypass the error knowning what was meant?

I would advise browsers to let users know when it has encountered a
document that is not valid/is not understood, maybe just a little icon that
has a check mark if valid and an "X" if not. Not obtrusive. The problem is
twofold: a browser is not a validator (nor should it be), and it's the
responsibility of browsers to handle bad content, not choke on it. But upon
encountering an error, it's impossible to assume "what was meant". The
general nature of parsing errors is their ambiguity.

>(as I said earlier, I see no reason why most all end tags can not be

Many can be assumed, hence the DTD's declaring them as optional. For
others, the lack of and end tag creates an ambiguity that cannot be


     Murray Altheim, Program Manager
     Spyglass, Inc., Cambridge, Massachusetts
     email: <>
     http:  <>
            "Give a monkey the tools and he'll eventually build a typewriter."