开发者

Youtube videos observe onclick

I'm trying to handle an event when the user click on a Youtube embedded videos to start them. Each video is included in a <li> element which, again, is included in a <div> container. Like:

<div class="container">
<ul>
<li><embed src="..."></embed></li>
<li><embed src="..."></embed></li>
</ul>
</div>

This container is a prototype scroller which automatically go next after a time (by setInterval). I want that, on observe (click) on videos, the autoScroll stops (by clearInterval).

Neither observing clicking on embed or li elements works but, with Firefox, the observing on the container element works, allowing me to clear the interval.

The problem is that only Firefox works, other browsers don't get the observe method on it.

Any so开发者_JAVA百科lution?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜