Menu

02 July 2009

html5 video seek bar control in Firefox 3.5

So you want a html5 video tag seek bar control in firefox3.5+ ?
Here is the answer !!

Let support your video tag is like this --

< video id="video_source" src="sound.ogg">
Your browser does not support the video element.
</video>

in javscript you can do lot of stuff like

var video = document.getElementById("video_source");
video.play(); //for play
video.pause(); //for pause
var curr_time = video.currentTime ;// this will give a seek bar time, Or simply elapsed time
//for restarting the video
video.currentTime = 0;



I am also trying to play with controlling other parameters like volume and other things !! Say Tuned !!



No comments: