Hi,
1/ I know some parts of FileWriter API do already exist in Chromium
(BlobBuilder), but I'm asking about being actually able to save file
to disc. I've been looking for some plans, but could not find any. Is
there any time frame for this? Like 2 weeks, 2 months? Any?
2/ I'd also like to ask about the actual process of selecting the
target file. I've googled some discussions about <input type="saveas" /
> element, window.saveAs method, discussion about dialog blocking,
etc. Is there any conclusion about this?
3/ I've been testing BlobBuilder and I'm vaning problems with
ArrayBuffer, this kind of object should be appendable to blob, but I
cannot make it work:
var b = new ArrayBuffer(8);
var v1 = new Int32Array(2);
v1[0] = 65;
v1[1] = 66;
var bb = new BlobBuilder();
bb.append("Lorem ipsum");
bb.append(v1.buffer);
bb.append(b);
var bl = bb.getBlob();
var reader = new FileReader();
reader.onload = function(event)
{
alert(event.target.result);
};
reader.readAsBinaryString(bl);
displayed message shows: Lorem ipsum[object ArrayBuffer][object
ArrayBuffer]
http://dev.w3.org/2009/dap/file-system/file-writer.html#the-blobbuilder-interface
http://www.w3.org/TR/file-writer-api/#the-blobbuilder-interface
one draft specifies this method, one does not... Am I doing something
wrong or is this just not implemented in Chromium yet? Tested in
Cromium 8.0.558
--
You received this message because you are subscribed to the Google Groups "Chromium HTML5" group.
To post to this group, send email to chromiu...@chromium.org.
To unsubscribe from this group, send email to chromium-html...@chromium.org.
For more options, visit this group at http://groups.google.com/a/chromium.org/group/chromium-html5/?hl=en.
On Oct 26, 5:25 pm, Eric Uhrhane <er...@chromium.org> wrote:
> On Mon, Oct 25, 2010 at 8:28 PM, Bauglir <Bronislav.Klu...@bauglir.com>wrote:
>So the point being: there is no way to write file to harddisc using
> > Hi,
> > 1/ I know some parts of FileWriter API do already exist in Chromium
> > (BlobBuilder), but I'm asking about being actually able to save file
> > to disc. I've been looking for some plans, but could not find any. Is
> > there any time frame for this? Like 2 weeks, 2 months? Any?
>
> The FileSystem API is being implemented now. We don't have quota support in
> yet, so at the moment you need to be using an extension or app with
> unlimited storage quota permissions, and you need to be running fairly new
> code from the nightly build. This allows saving inside the sandbox, but
> doesn't have FileSaver support at this time.
FileWriter API and noone knows when it might be?
Just asking whether to wait for it or come up with my own solution :)
I've only found window.saveAs in non-normative example in those
>
> > 2/ I'd also like to ask about the actual process of selecting the
> > target file. I've googled some discussions about <input type="saveas" /
> > > element, window.saveAs method, discussion about dialog blocking,
> > etc. Is there any conclusion about this?
>
> It's in the spec, but nobody is implementing it yet.
>
specifications, but not in HTML5 draft, saveas input is only mentioned
in some chromium discussion groups. So I don't know which of those
methods are in which specifications :)
Brona
To post to this group, send email to chromiu...@chromium.org.
To unsubscribe from this group, send email to chromium-html...@chromium.org.
Rudie Dirkx
Thanks!
--
Greetlingss,
Rudie Dirkx
Hi,I use it in http://appmator.appspot.com (https://github.com/PaulKinlan/Appmator/blob/master/static/index.html).In Chrome you can create an iframe and set the src to be the blob (object) - this will make Chrome initiate a download.
var bb = new BlobBuilder();
var output = Builder.output({"binary":true});var ui8a = new Uint8Array(output.length);for(var i = 0; i< output.length; i++) {ui8a[i] = output.charCodeAt(i);}bb.append(ui8a.buffer);var blob = bb.getBlob("application/octet-stream");var saveas = document.createElement("iframe");saveas.style.display = "none";if(!!window.createObjectURL == false) {saveas.src = window.webkitURL.createObjectURL(blob);}else {saveas.src = window.createObjectURL(blob);}
Thanks,P
Paul Kinlan
Developer Advocate @ Google for Chrome and HTML5
t: +447730517944
tw: @Paul_Kinlan
LinkedIn: http://uk.linkedin.com/in/paulkinlan
Blog: http://paul.kinlan.me
Skype: paul.kinlan
--You received this message because you are subscribed to the Google Groups "Chromium HTML5" group.
To post to this group, send email to chromiu...@chromium.org.
To unsubscribe from this group, send email to chromium-html...@chromium.org.
For more options, visit this group at http://groups.google.com/a/chromium.org/group/chromium-html5/?hl=en.
var bb = new BlobBuilder();
var output = Builder.output({"binary":true});var ui8a = new Uint8Array(output.length);for(var i = 0; i< output.length; i++) {ui8a[i] = output.charCodeAt(i);}bb.append(ui8a.buffer);var blob = bb.getBlob("application/octet-stream");var saveas = document.createElement("iframe");saveas.style.display = "none";if(!!window.createObjectURL == false) {saveas.src = window.webkitURL.createObjectURL(blob);}else {saveas.src = window.createObjectURL(blob);}
Thanks,P