Re: Closing tags

Martian (abigail@mars.ic.iaf.nl)
Wed, 12 Apr 1995 04:21:22 +0200 (MET DST)


Message-Id: <m0rys3X-0002GVC@mars.ic.iaf.nl>
From: abigail@mars.ic.iaf.nl (Martian)
Subject: Re: Closing tags
To: trondare@hsr.no
Date: Wed, 12 Apr 1995 04:21:22 +0200 (MET DST)
Cc: www-html@www10.w3.org
In-Reply-To: <Pine.3.89.9504111904.A28437-0100000@gorina1.hsr.no> from "Trond Are Undem" at Apr 11, 95 02:30:22 pm

Once upon a time you, Trond Are Undem, wrote:
--> 
--> On Tue, 4 Apr 1995, Jeffrey Hobbs wrote:
--> 
--> > >What's right to use according to the standard and standards to come of 
--> > >the following:
--> > >
--> > >    <P></P>, <LI></LI>, <DT></DT>, <DD></DD>
--> > >
--> > >or without closing tags
--> > 
--> > Browsers should handle these with or without closing tags, but editors
--> > _should_ generate perfect HTML, meaning they should write it out with
--> > close tags.
--> 
--> I see ... thanks for your help :)
--> 

Well, not having the closing tags for <P>, <LI> etc *is* perfect HTML.
>From the DTD:

<!ELEMENT P  - O (%text)+>
<!ELEMENT DT - O (%text)+>
<!ELEMENT DD - O  %flow;>
<!ELEMENT LI - O  %flow; -- list item -->

The `-' after the element name  indicates the opening tag is required,
the `O' in the  second field after the name indicates  the closing tag
is  optional. Hence,  using <P>,  <LI>,  <DT> and  <DD> without  </P>,
</LI>, </DT> and </DD> *is* perfect HTML.


Abigail