We have a youtube player embedded in a plage in Mobile Safari and it works great. But we need to be able to launch the youtube player by a means other than user tapping the video itself, for various reasons.
So I am trying to figure out what event to trigger in javascript to make it happen with no luck. None of the following appear to work.
var vid = document.getElementById('vid');
vid.click();
vid.onclick();
vid.ontouchend();
vid.ontouchstart();
vid.focus();
I tried to find an event handler added to the embedded object with this snippet, but didn't find anything.
for (var key in vid) {
if (typeof vid[key] == 'function') console.log(key +': '+ vid[key]);
}
Is this just so wrapped up in a custom plugin there is no way?