Autoplay does not function in chrome when used with data-setup or in the video tag itself.
Explain in detail the exact steps necessary to reproduce the issue.
https://jsfiddle.net/afridley/dvLgr1cb/
Autoplay functions in chrome
The video does not autoplay
Please include any additional information necessary here. Including the following:
Latest cdn 7.0.4
Chrome Version 70.0.3538.102
Mac OS mojave
馃憢 Thanks for opening your first issue here! 馃憢
If you're reporting a 馃悶 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.
This is expected. Browsers now will not autoplay by default anymore, unless the video is muted. To that end, we have extra values for the autoplay option to video.js: https://docs.videojs.com/tutorial-options.html#autoplay. However, that option seems to not be working properly right now, and it's something we should fix.
For more information on autoplay, you should check out our autoplay best practices blogpost.
I have added the muted tag to the example but the player still is not working in chrome 70. I also added a standard html5 video player with the same attributes that does autoplay. I would expect videojs to function in a similar way as the default player in regards to these attributes.
Yeah, there's definitely something weird going on, we'll take a look.
Looking into this a bit, it seems like there's some weird timing issue. I can't reproduce it at all locally but if I create a new page on say codepen, I can reproduce it. And there's more chatter of things being an issue in #4720.
This issue is already running with version 70 of chrome. I can't understand in which commit that happen and why this issue is still opened.
thanks
Yeah it definitely looks like it's the same issue as #4720
Both the solutions that were posted there seem to work
var player = videojs('video_delay');
player.ready(function() {
setTimeout(function() {
player.autoplay('muted');
player.fluid('true')
}, 1000);
});
var video = $("video").get(2);
video.load();
video.play();
if (video.paused) {
location.reload(true);
}
I updated the fiddle to illustrate each of the fixes and current behavior https://jsfiddle.net/afridley/dvLgr1cb/
This seems to be fixed with Chrome 71.
It's happening with chrome latest version(71) and videojs version 7.3.0. Can someone help me to resolve this issue.
@joe455 you can see autoplay still being broken in chrome 71 with Video.js 7.3? What OS are you on? Do you have an example?
The fiddle created by @afridley works great for me in chrome 71 on macos currently.
Also, I want to redirect this issue into #5233 so that we have only one issue on going related to this.