HTML5 Guidelines for Web Developers

(coco) #1
4.6 Interim Solutions for Older Browsers 83

Table 4.4 Codec support in current browsers


Codec Firefox Opera Chrome Safari IE iOS* Android
OGG 3.5 10.50 3.0
MP4 3.0 3.0 2.0
WebM 4.0 10.60 6.0 9**
Flash Plug-In Plug-In Plug-In Plug-In Plug-In 2.2


  • Apple’s operating system for mobile devices, such as iPhone, iPad, iPod (since June
    2010 iOS, previously iPhone OS).
    ** According to Microsoft, the WebM codec must be installed in the operating system,
    unlike with other browsers.


4.6 Interim Solutions for Older Browsers


Fortunately, not every web developer who wants to cater to different platforms
or browsers has to completely reinvent the wheel. There are several free libraries
online focusing on this problem. Currently, Kaltura’s JavaScript library mwEm-
bed has reached a very good stage of development. Wikipedia uses it to make
video and audio elements available for most platforms. The main focus of this
library is on the Ogg format. If you want to offer WebM and MP4 as well, use of
the html5media library is a good solution.


4.6.1 mwEmbed


The mwEmbed library gained wider recognition mainly through the integra-
tion in Wikipedia. Kaltura, the company behind mwEmbed, offers integration
not only for MediaWiki, the free encyclopedia’s wiki software, but also for ready-
made plug-ins for common CMS and blog software like Drupal or WordPress.


To ensure that even older browsers do not choke on the new HTML5 syntax, this
example adds the elements head and body:


<!DOCTYPE html>




mwEmbed fallback



mwEmbed fallback


Free download pdf