W3C home > Mailing lists > Public > public-html@w3.org > June 2010

Re: HTML4 Diffs - Object, again

From: Leif Halvard Silli <xn--mlform-iua@xn--mlform-iua.no>
Date: Sun, 27 Jun 2010 17:24:19 +0200
To: Kornel Lesinski <kornel@geekhood.net>
Cc: public-html@w3.org
Message-ID: <20100627172419726320.b2d9c383@xn--mlform-iua.no>
Leif Halvard Silli, Sun, 27 Jun 2010 16:45:59 +0200:
> Kornel Lesinski, Sun, 27 Jun 2010 15:12:54 +0100:
>> On Sun, 27 Jun 2010 05:48:16 +0100, Leif Halvard Silli:
>>> And also: Every time the HTML4 validator discover an element in an
>>> illegal context, it typically tells you to nest it inside a <object> or
>>> <map> or <button> if you want to have it there.
>>> I find it hard to believe that all these things are side effects of the
>>> fact that HTML4 is expressed as a DTD.
>> Note that analogous use of <INS> and <DEL> is explicitly forbidden 
>> in HTML4:
>> http://www.w3.org/TR/html401/struct/text.html#h-9.4
> I suppose you mean this: ?
> ]]
>     The following is not legal HTML.
>     <P>
>     <INS><DIV>...block-level content...</DIV></INS>
>     </P>
> [[
>> Given that I think it was not intention to have "wildcard" elements 
>> in HTML 4 that allow violation of content model "if you want to have 
>> it there".
> I do not follow, at all. The purpose of <object> is to _embed_ things - 
> including fallback. Whereas the purpose of <ins> and <del> is to show 
> editorial changes. 
> With regard to the example from HTML4 above, then it would not be 
> possible, due to limitations of HTML that Baron explained, if it did 
> not contain the <ins> element. That is, the following version does not 
> reflect the DOM of the illegal HTML4 example:
>     <P>
>        <DIV>...block-level content...</DIV>
>     </P>
> And hence, since it is not possible to have code like that in HTML, it 
> also does not make sense to make it legal via <ins> or <del>. It would 
> be to permit authors to cheat/lie if it were permitted. The purpose of 
> <ins> and <del> is not to document that the author corrected his/her 
> code from illegal code//impossible DOM to legal code/possible DOM! 

With regard to your comments about the HTML4 validator:

]] Personally I don't like the error message suggesting insertion of 
<object>, because it's misleading. It's extremely unlikely that author 
wanted to embed an object, put fallback in, but forgot the <object> 
element itself. [[  [et cetera]

So, if we try to validaete <h1><h2></h2></h1>, the we get:

[In the W3 _XHTML1_ validator:]  Line 9, Column 8: document type does 
not allow element "h2" here; missing one of "object", "applet", "map", 
"iframe", "button", "ins", "del" start-tag

[In the W3 _HTML4_ validator:]   Line 9, Column 8: document type does 
not allow element "H2" here; missing one of "APPLET", "OBJECT", "MAP", 
"IFRAME", "BUTTON" start-tag

I must admit that it does not rhyme with my thinking that XHTML allows 
<ins> and <del> here - this to me seems like a bug in the XHTML 
validation service. Which I have now filed. 
leif halvard silli
Received on Sunday, 27 June 2010 15:24:53 UTC

This archive was generated by hypermail 2.4.0 : Saturday, 9 October 2021 18:45:20 UTC