Lesson 8. Using Video and Audio

HTML5 lets you play video with ease—just use the <video> element.

Currently, however, most browsers that let you play video only play videos in .ogg format, a relatively obscure open-source format. Fortunately, you can convert videos from almost any format into .ogg format. In addition, some browsers enable you to use other video formats with the <video> element.

In this lesson, we’ll play an .ogg video in an HTML5 web page, including displaying controls so the user can control playback.

We’ll also take a look at playing audio in this lesson with the new <audio> element.

Tip

One reason the <video> element is so eagerly anticipated is because the Apple iPad does not play Flash video, and the <video> element may ...

Get Sams Teach Yourself HTML5 in 10 Minutes now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.