autoplay muted video iOS 11.2

非 Y 不嫁゛ 提交于 2019-12-09 19:39:19

问题


I am currently working on a page with videos on it. Since iOS 11.2, it seems they disabled autoplay muted inlineplaying completely without a user gesture.

Has anyone experienced this issue too?

This all wouldn't be such a mess if there would be a possibilty to check whether it is possible to playinline or not. But like this it results in a new hack by UA sniffing.

Edit: I have seen that i am have missed something. Autoplay is working, but trying to video.play() a muted inline video is not working anymore.


回答1:


Just turn off the "Low Power Mode" ;)




回答2:


Found a working solution thanks to the WebRTC repo (works in iOS 11.2.5):

Set the video's playsinline attribute to true.

References:

  • https://github.com/webrtc/samples/issues/929#issuecomment-330816567
  • https://webkit.org/blog/6784/new-video-policies-for-ios/ (check the note about vendor prefixes)


来源:https://stackoverflow.com/questions/47655077/autoplay-muted-video-ios-11-2

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!