Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autoplay videos occasionally fail to play in Safari 11 #560

Closed
bwnodak opened this issue Mar 13, 2018 · 5 comments
Closed

Autoplay videos occasionally fail to play in Safari 11 #560

bwnodak opened this issue Mar 13, 2018 · 5 comments
Assignees
Labels

Comments

@bwnodak
Copy link

bwnodak commented Mar 13, 2018

I'm running into an issue where autoplay videos are inconsistent in Safari 11 (but fine in Chrome and Firefox). Specifically, triggered events in videojs-contrib-ads (preroll) sometimes do nothing and the video requires a click to play, even though the video element has muted=true and autoplay.

Using:

  • video.js@6.7.3
  • videojs-ima@1.2.1
  • videojs-contrib-ads@6.0.0

To clarify, the video plays correctly with preroll ads about 70% of the time, with this debug output from videojs-contrib-ads:

screen shot 2018-03-13 at 2 32 03 pm

About 30% of the time, the adsready event is triggered with no subsequent events, causing the video to no autoplay:

screen shot 2018-03-13 at 2 32 55 pm

The AdTagURL being tested is:

https://pubads.g.doubleclick.net/gampad/ads?correlator=2179236500362919&cust_params=beta%3D0%26google%3D1%26slot%3Dvideo%26test%3Dhouseads%26video_service%3D3%26video_id%3Dm2jtspultyvb4avdhubv%26player_version%3D2.1.3%26categories%3Darts-and-entertainment-movies%2Carts-and-entertainment-television%2Carts-and-entertainment%2Carts-and-entertainment-celebrity-fan-sla%26player%3D2.1.4%26ap%3D2%26ctp%3D0&description_url=http%3A%2F%2Fwww.thehollywoodgossip.com&env=vp&gdfp_req=1&iu=%2F1030006%2Fthehollywoodgossip_video&output=xml_vast3&sz=640x480&unviewed_position_start=1&url=null&eid=324123020%2C495644009&sdkv=h.3.195.4&sdki=3c0d&scor=554421001053338&adk=2876963133&u_so=l&osd=2&frm=0&sdr=1&is_amp=0&vpa=auto&vpmute=0&mpt=videojs-ima&mpv=1.2.1&afvsz=200x200%2C250x250%2C300x250%2C450x50%2C468x60%2C480x70&ged=ve4_td1_tt0_pd1_la1000_er0.0.0.0_vi0.0.1321.637_vp0_eb16491

Any guidance would be appreciated!

@ypavlotsky ypavlotsky self-assigned this Mar 14, 2018
@ibraalek10
Copy link

Hi all,
Safari 11 blocks the video with autoplay and with sound.

doc: https://www.howtogeek.com/326532/safari-now-disables-auto-playing-videos.-heres-how-to-allow-them-for-certain-sites/

A.

@ehoch
Copy link
Contributor

ehoch commented Mar 14, 2018

@ibraalek10 As mentioned in the issue, this is on videos with the muted attribute.

@ibraalek10
Copy link

Yes, but i had same problems months ago also with the "muted" attribute..
For this reason i shared this article..
Take a test..

A.

@ypavlotsky
Copy link
Contributor

I'm not seeing this in using our autoplay example when I replace the tag with your tag. We're also in the process of updating our autoplay example to be more robust here.

@ypavlotsky
Copy link
Contributor

Going to close this out as there hasn't been some activity here for a while. Feel free to reopen if this is still an issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants