[whatwg] Indicate a file name for data: URLs?

Philip Jägenstedt philipj at opera.com
Mon Mar 21 05:05:23 PDT 2011


On http://foolip.org/microdatajs/live/#json I have a "Download it!"  
function which uses data: URLs to save JSON generated by JavaScript. The  
only real limitation with this approach is that one cannot suggest a file  
name, so in Opera the suggested file name is "default".

Are there other ways to save script-generated data that don't involve  
bouncing against a server? If not, any ideas how one might fix this with  
data: URLs? The Content-Disposition header solves this problem, but can't  
be applied here.

-- 
Philip Jägenstedt
Core Developer
Opera Software


More information about the whatwg mailing list