Autoplay Scripting

Back to Overview
00:00 --> 00:07
Talking about autoplay, this is a functionality that you should generally avoid.

00:08 --> 00:15
I have never come across a website that I deemed accessible that autoplayed video.

00:16 --> 00:22
So just don't use it, especially like these big background videos.

00:22 --> 00:28
They can be very hard for people with certain cognitive disabilities.

00:28 --> 00:38
to ignore and they distract from the content. It's just not a good way to do it.

00:39 --> 00:45
The nice thing about HTML video elements is that most browsers now give you the option to

00:45 --> 00:54
completely disable autoplaying videos. So this is a screenshot of a very old version of Safari.

00:54 --> 01:00
And basically you can say autoplay, stop all, never autoplay.

01:00 --> 01:04
Or you can say I only want silent videos to autoplay.

01:04 --> 01:16
So you can make that decision on a general global basis and on a website by website basis.

01:16 --> 01:20
Both elements, audio and video, are completely scriptable.

01:20 --> 01:25
That means if you want to use your own UI, you can actually do that.

01:26 --> 01:35
And you can use, you know, normal HTML buttons and UI elements and users can click on that.

01:35 --> 01:37
And this is the preferred way to do this.

01:38 --> 02:02
And so if you're testing stuff for audio and video and audio or video element is used, which should be like 99% of all cases these days, then, you know, you just need to look at like, oh, does this pause button, is that available using the tab key?

02:02 --> 02:08
Is that reacting to keyboard access and stuff like that?

02:08 --> 02:16
So you don't need to do anything extra because these elements have that capability, which is super nice.