W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2009

Re: [FileAPI] File.mediaType

From: Arun Ranganathan <arun@mozilla.com>
Date: Fri, 13 Nov 2009 02:36:33 -0800
Message-ID: <4AFD36B1.9020200@mozilla.com>
To: Anne van Kesteren <annevk@opera.com>
CC: WebApps WG <public-webapps@w3.org>
Anne van Kesteren wrote:
> This should be a bit more exact as to how the mediaType is returned. I 
> would prefer ASCII-lowercase. 

Done.

> Returning "application/octet-stream" rather than null also seems 
> better if the type is not known. That way you do not have to type 
> check. Other parts of the platform also handle 
> "application/octet-stream" as unknown.

It's been pointed out that user agents type check on files.  If the 
mediaType is not known, users invoking the attribute can't do anything 
useful with it, so null is better.  What are the use cases for using 
application/octet-stream instead?
>
> Also, maybe we should just call this type? File.type seems unambiguous 
> enough.
>

"mediaType" is more specific than "type".

-- A*
Received on Friday, 13 November 2009 10:37:14 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:35 GMT