Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Launch Media Triggers on looped videos

Ben_Step
Level 2
Level 2

We are using the Media Events in Launch to trigger start/25%/50%/75%/100% video tracking.  The problem is that all the videos on the site are short looped ones, so we are getting loads of duplicated events as the video triggers.

 

Is there a way to set the Media events to only trigger once per video?  I looked into adding an extra action with a $("video").off() jQuery call to remove the handler, but couldn't work out what handler to remove.

1 Accepted Solution
Ben_Step
Correct answer by
Level 2
Level 2

I've come up with a work around - I've added a custom code condition that writes an entry into session storage with the name of the video, and only returns true if the session object isn't present.

This seems to have worked and means the calls are only being triggered once per session.

View solution in original post

1 Reply
Ben_Step
Correct answer by
Level 2
Level 2

I've come up with a work around - I've added a custom code condition that writes an entry into session storage with the name of the video, and only returns true if the session object isn't present.

This seems to have worked and means the calls are only being triggered once per session.

View solution in original post