I gave the code that I used below to pause youtube video in an iframe that accepts a function with no parameters and return type. Please let me know how I can get the playerβs status (ended, played, not started and similar) using the following code:
window.frames[playerName].postMessage(JSON.stringify({ "event": "command", "func": function, "args": 0, "id": 1 /*Can be omitted.*/ }), "*");
source share