Player events & playback sync
That flow relies on cross-window communication via
Say, you may listen to an event that video is paused or start video playback using your custom button. Our iFrames helpers can cover one use-case out-of-the-box: make sure that only one player is active at a time.
Iframely recognizes YouTube, Vimeo, SoundCloud, Dailymotion, Brightcove, Streamable, Vid.me, Facebook videos, Wistia, Coub, all MP4 videos (+ friendly gifs), Office Mix, sendvid, playstv.
We constantly monitor, discover and add new publishers that can fit into unified events API.
Player events API
Iframely events API follows Player.js spec, published under Creative Commons by our colleagues from Embedly.
&playerjs=trueto your API calls to get Iframely iFrames that follow Player.js spec. It works when Iframely iFrame is returned.
- To orchestrate the players, you can get player.js library on GitHub, or simply listen to the specified events yourself.
- If you use Iframely JSON as your API format, check
relarray attribute. We add
playerjsvalue there if we could make player be compatible.
The most common use case for player events is to synchronize playback accross multiple videos on your site. So that when user clicks to play a new video - the one that is already playing will stop automatically.
Iframely covers this feature without the need to handle events on your side. Simply activate it in your player settings, and Iframely will let only one video play at a time (among popular players that we can control).
Here's the playback sync in action. Try starting a video, and then another. It works across multiple browser tabs too.