Triggering a function when an Event Video ends

I wanted a ‘next’ button to appear AFTER an event video finished playing.  There might be a way of achieving this with the timeline, but I thought this method worked better.

1. Create a ‘next’ button and ID name it ‘nextBtn’.

2. Hide the button (press the eyeball)

3. Import your event video onto the frame (name does not matter)

4. Execute Javascript on the frame

5. Enter in the following code:

document.getElementsByTagName(“video”)[0].addEventListener(‘ended’,yourFunction,false);

function yourFunction(e) {

cp.show(“nextBtn”);

}

6. Watch and enjoy

Notes

You can add lots of other stuff to this trigger.  I update variables so that the LMS will store and ‘remember’ if a user watched the video or not. I also have a little check mark icon show next to the video.

Read the full story by

Tags:

RELATED READS
Top 4 Proven Instructional Design Strategies to Enhance eLearning for Corporate Training Shake Up Your eLearning With Our New Storyline Style
We are updating our Privacy Policy, so please make sure you take a minute to review it. As of May 25, 2018 your continued use of our services will be subject to this new Privacy Policy.
Review Privacy Policy OK