W3C home > Mailing lists > Public > whatwg@whatwg.org > February 2011

[whatwg] File inputs, @accept, and expected behavior

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Wed, 2 Feb 2011 15:21:36 -0800
Message-ID: <AANLkTikp=g8PabM3VcGsP=Y6vDGa3jKB5_CZcg-yE5qY@mail.gmail.com>
The file input gained the @accept attribute a little while ago, to
indicate what type of file should be accepted.  It has three special
values, "image/*", "video/*", and "audio/*".

I believe one intent of these special values is that browsers may
offer the user the ability to capture an image/video/audio with the
webcam/mic and automatically set it as the value of the <input>,
without the user having to create an intermediary file themselves.

The spec doesn't give any indication of this, though, and I've
surprised some people (browser devs, internally) when I tell them
about @accept after they ask me about access the webcam/mic.

Could we get a note added to the File Input section describing this intention?

Received on Wednesday, 2 February 2011 15:21:36 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:30 UTC