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

Tab Atkins Jr. On 09-10-23 04.28:

> On Thu, Oct 22, 2009 at 9:23 PM, Joe D Williams <> wrote:
>> Hi Ian,
>> " ... are only short-term workarounds, and the same applies to, e.g.,
>> <source> in <video>, or <command>, ... "
>> this quote was in another topic but it caught my eye because I'm not sure
>> how <source> constitutes a workaround; what is the problem allowing multiple
>> <source > elements is not solving?

   [ ... ]

> You misunderstood slightly.  ^_^  Ian was referring to the fact that
> <source>, being a new void element, doesn't work properly in current
> browsers (they treat it as as the start tag of an unknown element).
> <command> is another new void element with similar problems.

So what's the workaround for <source>? XHTML syntax?

<source /> is valid HTML 5 and, when created via 
document.createElement(), works perfectly in IE6: it isn't treated 
as the start tag of a unknown element. And creating workarounds 
for other legacy browsers than Internet Explorer, is not nearly as 
common ...

<source></source> also works. So, to validate as XML and serve as 
text/html would work ...

<source> has one "advantage" over <source/> and <source></source>: 
Support has to be hard coded into the Web browser - it doesn't 
rely on the "distributed extensibility" of using non-void elements.

Perhaps that's the crux?
leif halvard silli

Received on Friday, 23 October 2009 16:29:58 UTC