Is there a widely supported video playback technology for web pages that provides an event/hook that can be captured from Javascript when playback reaches the end of the stream?
My goal is to provide a web page that plays a video and then asks the user a question about the video once playback is plete. The question would be hidden or disabled until they have actually viewed the video.
Is there a widely supported video playback technology for web pages that provides an event/hook that can be captured from Javascript when playback reaches the end of the stream?
My goal is to provide a web page that plays a video and then asks the user a question about the video once playback is plete. The question would be hidden or disabled until they have actually viewed the video.
Share Improve this question asked May 19, 2010 at 23:17 Eric J.Eric J. 150k65 gold badges352 silver badges560 bronze badges2 Answers
Reset to default 12html5 video has an onended attribute
video.onended = function(e) {
// do stuff
}
you can fallback to the JW flash player that has an api
I know that JWPlayer can fire a Javascript event when playback has pleted.
Source: http://developer.longtailvideo./trac/wiki/Player5Events