W3C home > Mailing lists > Public > public-webapps@w3.org > July to September 2011

Re: [XHR2] Blobs, names and FormData

From: Jonas Sicking <jonas@sicking.cc>
Date: Mon, 11 Jul 2011 10:02:02 -0700
Message-ID: <CA+c2ei-NxcyJr0X1-DfWMYz0C1z1yztWuE9BZ0nCJ=TkSUN=zg@mail.gmail.com>
To: Anne van Kesteren <annevk@opera.com>
Cc: Julian Reschke <julian.reschke@gmx.de>, Alfonso Martínez de Lizarrondo <amla70@gmail.com>, Adrian Bateman <adrianba@microsoft.com>, Webapps WG <public-webapps@w3.org>
2011/7/11 Anne van Kesteren <annevk@opera.com>:
> On Thu, 07 Jul 2011 03:00:55 +0200, Adrian Bateman <adrianba@microsoft.com>
> wrote:
>>
>> I was about to send a similar proposal. We'd prefer to add an optional
>> argument to append that specifies the filename. This is the smallest change
>> to
>> implementations and doesn't require developers to understand the
>> BlobBuilder in order to use FormData. Having to create another reference to
>> a Blob and probably deal with managing a File and Blob both pointing to the
>> same data seems
>> unnecessarily involved when all we want is to get the filename into the
>> FormData object.
>
> Isn't the smallest change just setting the file name to "blob" rather than
> the empty string? I suspect setting the filename might come up elsewhere too
> (e.g. file system API) so I'd rather not do it here.

Additionally, what is the use case of being able to set the filename
during a FormData submission? My perception was that the main use case
was to not get an empty filename as many serverside implementations of
multipart/form-data did not deal well with that. I so far have not
heard a reason to believe that having the ability to specify a precise
filename is a common use case, so it seems unnecessary to add syntax
sugar for that.

/ Jonas
Received on Monday, 11 July 2011 17:03:00 GMT

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