javascript - Link button with video time -
i'm trying show button when user reaches @ time of video, button appear when user has seen 20 minutes of video. have no thought it, appreciate inputs. thanks
well if video playing through html5 (a video tag) not embedded next code 1 route take.
// video element var video = document.getelementsbytagname('video')[0]; // add together event listener 'timeupdate' video.addeventlistener('timeupdate', function() { // 20 mins in seconds if ( this.currenttime == 1200) { // code add together button here... } }, false);
you should check out html5 audio/video api
javascript video video-streaming html5-video
No comments:
Post a Comment