[whatwg] Attribute proposal: <video autostart> (was: <video> element proposal)

Simon Pieters zcorpan at gmail.com
Sun Mar 18 18:28:35 PDT 2007

On Sat, 17 Mar 2007 11:58:02 +0100, Keryx Web <webmaster at keryx.se> wrote:

> Speaking about enforcing. When this element gets implemented there are a  
> few things I would demand from my browser:
> 1. That videos should never start to play without my consent. No more  
> bgsound-hellish experiences. Advertisers will protest, but I'd say it is  
> up to them to make their commercials so appealing that I'd want to play  
> the video in question.
> 1b. If not (1) That video does not play automatically in a window/tab  
> that does not sit in the foreground. I tend to scroll wheel click on  
> links a lot. if there is video content on the page that has just opened  
> behind the one I am currently in and I would like to watch it, I'd  
> definitely prefer to start it when I flip tabs.

I agree with this. Safari already does 1b for plugins; other browsers  
should do the same by default IMHO (perhaps having 1 as an about:config  
setting or something). Disabling autoplay with <video> for UAs would be  
fairly straightforward; just prevent play() from doing anything until the  
user clicks the video, or, for 1b, until the tab is in the forground. I  
don't know if the spec needs to say anything about this.

However, I don't think it's useful to make it unnecessarily hard for  
authors to suggest autoplaying either; that will just prevent adoption of  
<video>. When a video is the primary purpose of a page, I think just about  
every author wants to suggest autoplaying. Using script for this is not  
nice from the author's point of view, but if it's their only choise  
they'll either do it or continue to use Flash. Autoplaying video is a  
pretty common case on the Web.

Therefore (to ease authoring and thus help adoption) I would like to  
propose a new boolean attribute for <video>: autoplay="autoplay". It's  
presence would be equivalent to invocing play() on the video ASAP. (Please  
remember that this wouldn't force anything; see above.)

Simon Pieters

More information about the whatwg mailing list