W3C home > Mailing lists > Public > public-html@w3.org > February 2009

Re: ISSUE-4: Versioning, namespace URIs and MIME types

From: Robert J Burns <rob@robburns.com>
Date: Wed, 18 Feb 2009 11:00:20 -0600
Cc: HTML WG <public-html@w3.org>
Message-Id: <2D9F15F1-4A48-43F6-AA10-116198A017C6@robburns.com>
To: Boris Zbarsky <bzbarsky@MIT.EDU>
Hi Boris,

On Feb 18, 2009, at 10:40 AM, Boris Zbarsky wrote:

> Robert J Burns wrote:
>> I understand from the short example. And I also understand the  
>> longer example you provide. The scripting is simply a distraction.  
>> If the author is authoring to HTML5 then the author would not  
>> append child elements to the img element. So now you're producing  
>> invalid HTML5. If the author is producing XHTML2, then the author  
>> would not provide an alt attribute.  So you're also producing  
>> invalid XHTML2.
>
> I don't think the scripting is a distraction at all.  The key here  
> is that once the <img> element has been created the script wants to  
> show an image to the user using that element.  The script that  
> creates the element and the script doing the showing need not be the  
> same script, or authored by the same person (e.g. the script doing  
> the showing is a library that does general image-showing stuff  
> amongst other things; consumers pass in nodes to show the images  
> in).  The script doing the showing wants to provide fallback  
> content.  How is it supposed to do it?
>
> If the script can examine the node it's working with and determine  
> from that how it should show fallback content, that's ideal.  If it  
> can't, we have a problem.
>
> I suppose the library API could include a flag for "what kind of  
> html image are you actually giving me", but that seems like an  
> unfortunate artifact to foist off on script authors.  It also seems  
> like something people are likely to either forget or to get wrong,  
> assuming both HTML5 and XHTML2 are actually in use.

I still think this is a distraction because the question now being  
posed is that if a scripting author needs to implement much of what a  
UA (such as a general purpose rendering engine) already does, isn't  
that hard. Well yet I think it probably is pretty hard. But if a DOM/ 
Script author simply lets the UA handle things for them, then the  
scripting is not complicated at all. The browser will determine the  
proper handling of the element (and 'iimg' element or any other  
element).

>> However, the context provides all the information necessary to know  
>> how to process the document in the situation of a fully conforming  
>> document.
>
> While true in this particular case, the concern I have is being  
> unable to produce a conforming document even if you want to, if  
> you're doing it via the DOM.

Well the example given (but now snipped) was specifically about what  
to do when an author intentionally produces a non-conforming document.  
So if your concern is about conforming documents the script example  
given is even more of a distraction.

Take care,
Rob
Received on Wednesday, 18 February 2009 17:01:14 GMT

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