This is a quick tip for anyone that wants to place a video onto their website and make it play automatically.
If you check out the documentation, you will soon see that there is an attribute called
autoplay and you’d think that you could just use that and it would always work. Want to see an example?
The thing is though, it will not play in Chrome and the problem isn’t obvious.
The issue is that Chrome won’t autoplay those videos unless they are muted - no doubt to stop people getting a fright!
To resolve it, change the code to this, using the muted attribute:
And you are good to go.
Internet Explorer v11 and Firefox v66 will play the video if not muted. Chrome v73 won’t.
Hi! Did you find this useful or interesting? I have an email list coming soon, but in the meantime, if you ready anything you fancy chatting about, I would love to hear from you. You can contact me here or at stephen ‘at’ logicalmoon.com