W3C home > Mailing lists > Public > public-html@w3.org > April 2007

Re: Formal definition of HTML5 (was Re: Version information)

From: Dão Gottwald <dao@design-noir.de>
Date: Tue, 17 Apr 2007 19:32:17 +0200
Message-ID: <462504A1.2090803@design-noir.de>
To: Boris Zbarsky <bzbarsky@MIT.EDU>
CC: David Dailey <david.dailey@sru.edu>, public-html@w3.org, Ian Hickson <ian@hixie.ch>

So the WHATWG draft is indeed incompatible with what user agents do 
today, and HTML4 content isn't necessarily compatible with the WHATWG 
draft, right?

--Dao

Boris Zbarsky schrieb:
> 
> David Dailey wrote:
>> The W3C spec says
>> "The <http://www.w3.org/TR/html401/struct/tables.html#edef-TBODY>TBODY 
>> start tag is always required except when the table contains only one 
>> table body and no table head or foot sections.
> 
> Right.  When the start tag is not required, it is implied.
> 
> In particular, the DTD for HTML 4 says:
> 
> <!ELEMENT TABLE - -
>      (CAPTION?, (COL*|COLGROUP*), THEAD?, TFOOT?, TBODY+)>
> 
> which means <table> is allowed to contain an optional caption, some 
> col/colgroup tags, an optional thead, an optional tfoot, and tbody 
> tags.  It is NOT allowed to directly contain <tr>, for example.
> 
> At the same time, the DTD says
> 
>   <!ELEMENT TBODY    O O (TR)+           -- table body -->
> 
> Which means that the <tbody> element has optional start and end tags and 
> is allowed to contain <tr> elements.  The prose then further restricts 
> when the start tag is optional.
> 
> If an optional start tag is missing, the parser is required to 
> synthesize it, as I understand SGML.
> 
> This is actually one area of serious incompatibility between HTML4 and 
> XHTML1 (in the latter, the tbody is well and truly optional, which means 
> the same well-nested markup leads to a different DOM).
Received on Tuesday, 17 April 2007 17:32:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:15:53 GMT