随着 html5 视频的最新变化,无法再自动播放视频 (HTML 5 Video "autoplay" not automatically starting in CHROME)
但是,使用 youtube api,您仍然可以使用自动播放参数嵌入其中一个视频,并且它实际上会自动播放它。
这怎么可能?谷歌团队使用 Chrome 执行的双重标准
最佳答案
Chrome 通过白名单自动播放 Youtube 视频。
对于 Chrome 的全新安装,Google 将包含 1000 个启用了自动播放功能的网站的白名单。列入白名单的网站基于 Google 看到 highest percentage of visitors play[ing] media with sound
的网站。 .当您浏览时,白名单会随着您的浏览历史记录而增长。
更多信息可以在这里找到:Improving Autoplay in Chrome
If you don’t have browsing history, Chrome allows autoplay for over 1,000 sites where we see that the highest percentage of visitors play media with sound. As you browse the web, that list changes as Chrome learns and enables autoplay on sites where you play media with sound during most of your visits, and disables it on sites where you don’t.
关于javascript - Youtube 如何自动播放其视频?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53661399/