W3C home > Mailing lists > Public > html-tidy@w3.org > July to September 2001

RE: Tidy becomes less forgiving

From: Fred Bone <Fred.Bone@dial.pipex.com>
Date: Fri, 14 Sep 2001 10:35:00 +0100
To: Html-tidy@w3.org
Message-ID: <3BA1DD54.12584.63548B@localhost>
On 13 Sep 2001 at 17:50, Reitzel, Charlie wrote:

> Hi Allen,
> You are not the first to raise this sensible point.  However, Tidy strikes a
> sometimes uneasy balance between the HTML specs -plural- and what browsers
> actually do.  If there is a general rule, it might be stated, "1) Parse any
> and all markup to the degree possible.  2) Emit spec compliant HTML that
> renders the same on most browsers as the non-compliant input."  A bit messy,
> yes.  But I think that's what makes Tidy useful.
> Further, the spec does not directly address nesting <form> tags within
> various table tags (<table>, <tr>, <td>).  According to the HTML 3.2 DTD,
> <form> tags are not allowed at all within a table.  Only <tr>'s are allowed
> within <table>'s and only text elements are allowed within a <td>.  

Quote from the 3.2 reference spec:

> <!ELEMENT (th|td) - O %body.content>

That includes FORMs.

> <form>
> is a block level tag.  HTML 4 requires an additional intervening TBODY tag.
> So we are already playing fast and loose w/ the spec.  My only suggestion
> was to move the line over one notch - you've got to draw it somewhere.

TBODY is optional (implied) and has no effect on the permitted content 
of TD.

In both 3.2 and 4, you can nest a TABLE in a FORM or a FORM in a TD. You 
can't have one block-level element overlapping another. (And you can't 
have a FORM in a TD that's inside a FORM).
Received on Friday, 14 September 2001 05:35:36 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:50 UTC