W3C home > Mailing lists > Public > html-tidy@w3.org > April to June 2000

Re: <caption><h1> nested - Mac BBTidy

From: <html-tidy@war-of-the-worlds.org>
Date: Wed, 21 Jun 2000 10:53:13 -0500
Message-Id: <p04320400b5768f874b5e@[]>
To: html-tidy@w3.org
mac.bjarnedm@get2net.dk wrote:
>html-tidy@war-of-the-worlds.org wrote:

>> Solution:  don't put H1 inside CAPTION; it can't go there.

>But it works as intended and displayes a 'h1' table caption ???

Because the browsers are fault tolerant... to a fault.  "But it works!"
does not change the specification.  And Tidy conforms to the specification.
If you want an H1 caption, you have to use H1 before TABLE rather than

>iCab - furthermore - has its own html-checker and doesn't complain about this.

iCab's HTML checker is not a DTD-driven validator, misses a lot, and in
some cases report errors that are not errors.  But it also catches errors
that a validator would not since the DTD is not the sole measure of the

There's one way to satisfy a DTD-driven validator and allow H1 inside
CAPTION.  That's by using <CAPTION><INS><H1>...</H1></INS></CAPTION>.  INS
(and DEL) can break practically every DTD rule in a strictly DTD-compliant
way, but the full specification says it's a violation to use them that way.
(Effectively, INS and DEL should inherit the content model of their parent,
except where that model and the content model of INS and DEL are disjoint
(e.g., TABLE can contain INS, but INS can't contain anything that you can
put inside TABLE).)
Received on Wednesday, 21 June 2000 11:53:19 UTC

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