Wednesday, September 7, 2011

Book Review: HTML5 Media

By Shelley Powers
Paperback: 138 pages
Publisher: O'Reilly Media; 1 edition (August 17, 2011)
ISBN-10: 1449304451
ISBN-13: 978-1449304454

I understand that O'Reilly is publishing a series of hardcopy and ebooks that sport a rather modest page count in order to get the material to market very quickly. Shelley Powers' HTML5 Media is one of them. Please keep in mind this book isn't intended to teach you everything you want to know about HTML5 but rather, to show web developers how to insert HTML5 media elements into web pages using the new video and audio elements.

The book's front matter states that the target audience is web developers, authors, and designers who need to ramp up to using HTML5 video and audio elements fast. Hence the size of the book. No one wants to read through 800 pages when they need to do anything fast. Powers' book, with its scant 138 page count, is guaranteed to be a fast read...maybe. Actually, that depends on how much you already know. While the book doesn't require you have a lot of experience with actual video and audio files, you will need a background in CSS and JavaScript for this to make the most sense to you. Of course, if you are a designer or developer, that should go without saying.

While sample code is available, sample video and audio files are not. It's sort of a BYO...F (for files) affair. This is to keep the size of the downloadables manageable, so be prepared to have video and audio material of your own available (if you don't have much on hand, don't worry. Powers provides a number of resources where you'll be able to access what you need).

It's not just about the's about the browsers. You can be fabulous HTML5 designer but if your browser (or your customer's browser) doesn't support the audio and video elements, you might as well not bother. IE9 or later is required, but you can also work with Firefox 3.5 or Chrome 6 and do just fine. If you keep your browsers current, you have nothing to worry about.

I got to work right away with what I learned on page 2, creating a basic audio page and, by adding the controls attribute to the audio element, I could play a sample mp3 I had on my computer (Sleep Away by Bob Acri using Chrome 9.0 on Windows 7, in case you wanted to know).

With my first minor success completed, I decided to download the sample files for the book and went back to the preface to look for the link...and didn't find it. I found the usual boilerplate text under "Using Code Examples" and while Powers says in the "Examples" section that there is a downloadable, I couldn't see where she provided the URL. Fortunately, I had already looked up the book's site at and easily found the correct zip file (and remember, when you try to work with these files, you'll need to provide your own video and audio material and change the default names to the names of the files you're working with in the sample code).

The book presents its content in four chapters which covers the default use of the video and audio elements, customizing the media elements (this is where CSS and JavaScript experience starts to come in handy), and other, more advanced material, including media elements in SVG documents.

Frankly, I found working with this book to be a blast. It's short enough to not be overwhelming to the reader and to impart a real sense of accomplishment very quickly, but dense enough to provide practical information that can be leveraged into actual, real-world web projects (not all books do this). Doing a bit of research, I took a look at some of the other books Powers has written including Learning JavaScript, 2nd Edition and JavaScript Cookbook. HTML5 Media is another fine example of her writing and another fine book from O'Reilly.

If working with media files in HTML5 sounds like something you want or need to do, I'd recommend picking up a copy of this book.

No comments:

Post a Comment

Please make comments.