无需用户交互即可在 Safari 中自动播放 HTML 视频标签 [英] HTML video tag autoplay in Safari without user interaction

查看:54
本文介绍了无需用户交互即可在 Safari 中自动播放 HTML 视频标签的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在视频标签中有自动播放功能,但它仍然需要将鼠标悬停在上面.据我所知,这是因为它需要用户交互才能播放视频,因此用户不会因未经他们同意而播放的视频而烦恼.有没有办法绕过这个问题或伪造事件来欺骗浏览器?

I have autoplay in the video tag, but it still requires mousing over it. From what I read it's because it requires user interaction to play the video, so users won't be annoyed by videos playing without their consent. Is there a way to get around that or fake the event well enough to fool the browser?

推荐答案

没有.如果有办法愚弄它,苹果会在下一个版本中堵上这个漏洞.

No. And if there was a way to fool it, Apple would just close that loophole on the next release.

这篇关于无需用户交互即可在 Safari 中自动播放 HTML 视频标签的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆