jquery - How do I add a link into an HTML5 Video after a frame? -
i have html5 video wish display link on. when click said link video jump x number of frames further video. possible using javascript library such jquery?
yes, possible. essential place javascript code in project:
var myvideo = document.createelement('yourvideoid'); var curtime = video.currenttime;
this creates 2 variables hold video element , video time. after have done suggest take @ this article dev.opera.com.
in case need skip specific time on video. here's have do:
var mylinkbt= document.getelementbyid('mylinkid'); mylinkbt.addeventlistener("click", function (event) { event.preventdefault(); myvideo.currenttime = 7 /* time here */; myvideo.play(); }, false);
Comments
Post a Comment