Guy Nesher
Guy Nesher

Reputation: 1385

Youtube iframe API - Android fullscreen

I'm using the YouTube iframe api to embed a video. When playing the video on an iPhone, the video automatically switches to full screen mode. I was wondering if it's possible to force the same behavior on an Android? (currently the video is played inline, which doesn't look so good).

Upvotes: 5

Views: 3955

Answers (1)

Kim T
Kim T

Reputation: 6454

There is no way to automatically play the video fullscreen. The closest you could get is to put the player in a fullscreen div and autoplay it using the url params:

<iframe width="100%" height="100%" src="//www.youtube.com/embed/fSy6uh-GjCc?controls=0&amp;autoplay=1&amp;showinfo=0" frameborder="0" allowfullscreen></iframe>

Upvotes: 2

Related Questions