Player & Add event listeners #6

kvervo opened this Issue Dec 10, 2013 · 1 comment


None yet

2 participants



I am following the documentation ( and trying work with add event listeners.

On my local version AddEventListeners are not working.

I am trying the following code from the js console in Chrome after loading the player:
var p = document.getElementById("player");
p.addEventListener("loadStateChange", function(){ alert("LoadState") });

Tried to add event listeners for: loadStateChange, playStateChange , volumeChange, mutedChange, mediaError. None of this events seem to fire.


addEventListener(eventName:String, callbackFunctionName:String)

p.addEventListener("loadStateChange", "myFunction");
function myFunction(){ alert("LoadState") }
@kutu kutu closed this Dec 11, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment