This is example was to test if it was possible to create a video play list for IOS4 using MP4 video files. The below code will load a video in IOS 4 and/or IOS 3.2. Once the video has ended it will automatically play another video file. Please remember to test on a device that supports html5 with MP4 video support.
window.onload = function()
{
var videoPlayer = document.getElementById("video");
videoPlayer.load();
videoPlayer.play();
document.getElementById("video").addEventListener('ended',myEventHandler,false);
function myEventHandler(e) {
alert('ended');
if(!e) { e = window.event; }
var moduleVideo = './video/sintel-trailer.mp4';
videoPlayer.src = moduleVideo;
videoPlayer.load()
videoPlayer.play();
}
}
J.P. McGarrity.com Focusing on the Front End
-
Auto Start a Video Element in IOS 4
November 1, 2010 by J.P.Category: html5Tags: html5, ios4, Mobile Safari, video tag | Comments (0)
-
HTML 5 Wordpress Theme (Naked)
July 17, 2009 by J.P.
Here is an updated version of the Naked Wordpress theme to support HTML5.
Wordpress Naked has been put together by us as a simple Wordpress theme to assist developers that need to quickly implement a blog using Wordpress but don’t really have the time to spend looking under the hood in any detail or reading documentation when it comes to applying a custom theme (e.g. their clients’ design).
Find out more about the original theme.
Category: coding, css/html, html5Tags: html5, wordpress theme | Comments (14)
-
HTML 5 Bundle For Textmate
July 16, 2009 by J.P.
Here is a download to the HTML 5 Bundle I have started for Textmate. This is my first attempt at creating a bundle from scratch please provide feedback and requests and I will add them.
Update 7/19/2009
Updated 3/21/2010
Added localStorage SnippetsThe bundle has also been uploaded to Github.
Category: applications, coding, css/html, html5, osxTags: html5, textmate bundle | Comments (6)
-
Video Player with HTML 5
June 16, 2009 by J.P.With some of the latest browsers supporting HTML 5 I thought I go ahead and take a stab at trying to create a very basic video player using some of the new tags. What’s interesting is many times when flash would be needed for video and audio HTML 5 will be able to support such media types with just a little JS.
Here is a sample player using HTML 5 (Note this is at a very early stage and only has play/pause functionality).
<div id="myVideoContainer">
<video id="myVideo" src="../videos/WheretheWildThingsAre.mov" autoplay="autoplay">
<p>Sorry Your Browser Doesn't Support HTML 5. Safari 4 will support this video player, download it here</p>
</video>
</div>Related information:
Category: coding, css/htmlTags: Add new tag, html5, video | Comments (0)



