EMBED in OBJECT, and both in VIDEO

Mozilla staffer Chris Double has one of the best blogposts I’ve yet seen on using the currently-proposed VIDEO tag in a realworld environment. It’s more realistic than other markup I’ve seen in that it goes beyond a single-browser audience. I would have commented there, but he requires either Google notification, or OpenID (which has been funky for me), so I’ll make a larger blogpost about it instead.

One of the most interesting aspects is that he’s addressing the age-old nesting of OBJECT and EMBED tags by [drumroll] wrapping a VIDEO tag around them both… VIDEO tag on the outside, then an OBJECT tag, then on the inside an EMBED tag. It makes sense, considering how HTML4 blessed Microsoft’s later OBJECT while dysfunctionally deprecating Netscape’s original EMBED, but to see three nested tags just for one media element, I got a kick out of that, and you might too.

The real reason I wanted to comment was on Chris’s line about transport controls: “These fallback options don’t allow creating your own controls with JavaScript and using the nice HTML5 media API.” There’s hope… Flash, of course, has been providing the world’s computers with customizable UI elements for a very long time, no browser variance to worry about.

But you can still do it in JavaScript, if you prefer… the varied protocols for plugin/browser intercommunication have all been quickly supported by Flash, and it’s quite possible to have JavaScript control a Flash video. For practical work you’d also need to include the Microsoft protocols for browser/ActiveX intercommunication, to reach the majority of people on the web, but it’s doable.

(I know that other people have driven video from JavaScript before, but I’m not sure how to search it up… if you happen to know of existing libraries they might use, could you drop a note in comments here please?)

The unspoken question in all this, of course, is “Why?” Making two formats of a video is something that very few people would find worthwhile to do. But as an intellectual exercise it’s certainly novel… VIDEO enclosing OBJECT enclosing EMBED, the tagging inspires a certain perverse fascination. Check it out!