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

Re: [File API] data URL method

From: Jonas Sicking <jonas@sicking.cc>
Date: Thu, 2 Jul 2009 09:38:03 -0700
Message-ID: <63df84f0907020938g670e5c3aoc6b3435e2ca7c04@mail.gmail.com>
To: Anne van Kesteren <annevk@opera.com>
Cc: WebApps WG <public-webapps@w3.org>
On Thu, Jul 2, 2009 at 2:58 AM, Anne van Kesteren<annevk@opera.com> wrote:
> I tend to think that if we are going to introduce a URL scheme to point to file data on the system we should not be adding the data URL method. As far as I can tell there are no benefits to introducing it as it will only increase memory usage when used by authors and the uses it has can be perfectly achieved using the local file URL. Also, the local URL can be a synchronous API as there is no need to read the entire file directly and store it all into memory. You only need to return a URL.
> I.e. instead of
>  file.getAsDataURI(
>    function(dataURL) { img.src = dataURL }
>  )
> you would get
>  img.src = file.localURL
> which is better in many ways and not worse in any way I can think of (maybe apart from moving the discussion with the TAG regarding a new URL scheme a little bit ahead).

This would be a more interesting discussion if someone could actually
come up with a spec for localURL :)

Mostly it's the lifetime issue that concerns me. How long is such a
URL expected to work, and how do we prevent people from using it
longer than that?

/ Jonas
Received on Thursday, 2 July 2009 16:39:07 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:17 UTC