W3C home > Mailing lists > Public > www-html-editor@w3.org > April to June 2005

Re: HTML 4.01 Specification - query

From: David Håsäther <hasather@gmail.com>
Date: Fri, 06 May 2005 20:24:27 +0200
Message-ID: <427BB65B.2040709@gmail.com>
To: www-html-editor@w3.org

Norman Paterson wrote:

 > Not sure if this is a typo or my mistake.  Section 7.4.2 of
 > REC-HTML401-19991224 has:
 >     <!ELEMENT TITLE - - (#PCDATA) -(%head.misc;) -- document title
 > -->
 > where
 >     <!ENTITY % head.misc "SCRIPT|STYLE|META|LINK|OBJECT" --
 > repeatable head elements -->
 > I don't see why -(%head.misc;) is necessary in the element definition
 > of TITLE.

This is beacuse of the element declaration for HEAD:
<!ELEMENT HEAD O O (%head.content;) +(%head.misc;) -- document head -->

Here, head.misc is included which means that SCRIPT, STYLE, META, LINK 
and OBJECT are
allowed subelements for HEAD. But by doing this inclusion, they will 
also be allowed
subelements for TITLE, which is why they later are excluded.

 > If it is necessary, why is it not also necessary to forbid all other
 > elements besides those in %head.misc;

They are not allowed in the first place. The content model for TITLE is 

 > As far as I have been able to discover, PCDATA may contain character
 > references such as &lt; but no tag-based markup such as <EM>...</EM>;
 > which is consistent with -(%head.misc;) being unnecessary.

Yes, in PCDATA, all markup is recognized, but elements are not allowed.
About the exclusion of head.misc being unnecessary, that is already 
answered :)

David Håsäther
Received on Friday, 6 May 2005 18:25:01 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:08:53 UTC