Re: Short-term workarounds - - <source> in <video>

Maciej Stachowiak On 09-10-24 01.27:

> On Oct 23, 2009, at 3:41 PM, Leif Halvard Silli wrote:


>> If you serve your HTML 5 pages as XHTML, then you must either use  
>> <source /> or <source></source> - either is valid. The problem is  
>> that most pages will be served as text/html, where only "<source />"  
>> is valid.
>>
>> My point above was that most legacy browser installations (Internet  
>> Explorer) do not need any workaround, other than the "/>" at the  
>> end, because IE, in this situation, and unlike all other browsers,  
>> treats it as a element closing signal, like in XML.
>>
>> My point between the lines is that the text/html serialization of  
>> HTML 5 should permit not only "<source />" but also "<source></ 
>> source>" - that would be the simplest workaround of all - should  
>> work cross browser!
>>
>> Why can't HTML 5 permit that?
> 
> I think it would be reasonable (and perhaps on balance a good idea) to  
> allow a close tag for new void elements. Though it would have to  
> immediately follow the open tag - a close tag separated by content  
> would have to be treated as just a stray close tag and a parse error.  
> Otherwise the open tag alone wouldn't work, since you would have to  
> parse to the end of the document to know if there is a close tag.

Sounds reasonable! Filed a bug report for the issue [1] including 
a Liv DOM Viewer demo of browser behaviors [2].

[1] http://www.w3.org/Bugs/Public/show_bug.cgi?id=8038
[2] http://software.hixie.ch/utilities/js/live-dom-viewer/saved/288
-- 
leif halvard silli

Received on Saturday, 24 October 2009 22:35:09 UTC