3
Galera would have like through some javascript to make a video on my site not open on full screen on iOS devices?
Because I’m using youtube as a music player and every time someone accesses on iOS devices it opens the video on full screen. Follow my code with playsinline.
var buildPlayer = function(videoUrl)
{
playerLoading = true;
player = new YT.Player(attrs.container, {
height: '200',
width: '200',
videoId: getIdFromUrl(videoUrl),
playerVars: {
enablejsapi: 1,
playsinline: 1,
html5: 1,
},
events: {
'onReady': onPlayerReady,
'onStateChange': onStateChange
}
});
}
Can you put a reproducible example? I want to test but I don’t have a complete example.
– brasofilo
Can I guess iOS only opens in fullscreen anyway, after all it runs with the "native player". This could be a youtube BUG, because in the apple https://developer.apple.com/library/iad/documentation/UserExperience/Conceptual/iAdJSProgGuide/PlayingVideosinAds/PlayingVideosinAds.html says it works for "ads".
– Guilherme Nascimento