Extras
Controlling the embedded iframe player via postMessage events
Vidzflow embedded videos allow the integrator to control various operations of the video using postMessage
functionality.
Play
Code above will trigger play of the video.
Pause
Code above will trigger pause of the video.
Stop
To stop the video playback and reset it to the beginning:
Mute
To mute the video:
Unmute
To unmute the video:
Set volume
To set the volume:
Note: Values for setting the volume range from 0 to 1, with 0.1 steps.
Set time (seek)
To seek to specified time:
Note: The provided value is seconds.
Fullscreen
To open fullscreen:
Key Limitations:
Fullscreen Activation:
Limitation: The fullscreen functionality may not work if the user has not interacted with the player.
Explanation: Modern browsers enforce user interaction before allowing fullscreen mode to prevent disruptive experiences. This means that calling the
playerFullscreen
command via postMessage will only work if the user has already interacted with the iframe player (e.g., clicking on the player).
Unmute Function:
Limitation: The unmute functionality may not work if the user has not interacted with the player.
Explanation: Browsers typically require a user gesture (like a click) before allowing audio to play. This is a safeguard to prevent unwanted sound from autoplaying on a website. Therefore, the
playerUnmute
command will only be effective if the user has previously interacted with the iframe player.
Last updated