tylerpearson / lazyYT

A jQuery plugin to lazy load those dang Youtube iframe videos.
Other
208 stars 86 forks source link

Requires 2 clicks on mobile to play the video #22

Closed jaskaran27 closed 9 years ago

jaskaran27 commented 9 years ago

On mobile devices (Tested on Chrome on an Android) it takes 2 clicks to play the video. 1st click on the play button loads the youtube iframe, 2nd click on the play button loads the video. Anyone else having the same issue?

tyrann0us commented 9 years ago

The Plugin creates the YouTube iframe after the user has clicked the placeholder. Since Android and iOS disabled autoplay the user has to click again to make the actual video play. See here: https://developer.apple.com/library/safari/documentation/AudioVideo/Conceptual/Using_HTML5_Audio_Video/Device-SpecificConsiderations/Device-SpecificConsiderations.html#//apple_ref/doc/uid/TP40009523-CH5-SW4