It seems the problem boils down to needing to set the Content-
disposition header ("Content-disposition: attachment") to force a
'save as' dialog box. However, the captureBlob method only includes
the content-type parameter to set the MIME-type. I feel it should be
possible though and must be missing something.Is there any way to change the content-disposition header of files served by the localServer to force a 'Save As' dialog in all major browsers? Cheers, Martijn On Oct 24, 6:32 pm, MG <[email protected]> wrote: > Hello! > > I am using the following code to save a text file to a local computer: > > var srv = google.gears.factory.create('beta.localserver'); > var store = srv.createStore('mystore'); > var sResourceName = 'file.export'; > > sResourceName = escape(sResourceName); > > if( store.isCaptured(sResourceName)) > store.remove(sResourceName); > > store.captureBlob(blob, sResourceName, > 'application/octet-stream'); > > window.open(sResourceName, '_blank'); > setTimeout(function(){ > store.remove(sResourceName); > callback(true); > }, 1000); > > FF & Chrome properly open the save file/download window, but IE8 opens > the blob as text in a new browser window. Is there a way to force IE > to save the file instead of showing it in a window? > > Thanks, > MG
