If I replace a.click with code using document.createEvent() as Matěj Pokorný suggested, it works on FF but not IE. See MSDN about it. Mozilla is developing some such APIs for Firefox OS and they want to propose them as standard:https://developer.mozilla.org/en-US/docs/Web/Apps/ReferenceHowever, these APIs might be limited in another way: They aim at mobile platforms (mainly Of course the browser won't show a nice file name here.
strFileName The name of the file to be created. Specifying a filename If the blob is created with the File constructor, you can also set a filename, but only a few web browsers (including Chrome & Firefox) have support for share|improve this answer answered Dec 27 '13 at 6:55 dinesh ygv 702514 This requires jQuery. –Dan Dascalescu Nov 5 at 21:07 I just used jquery to attach For details, see our Site Policies.
Js Download File From Server
window.location = 'data:jpg/image;base64,/9j/4AAQSkZJR....' this works fine in firefox but not in chrome. Here is basically how I do it: 1) get all the content into a string called "content" (e.g. What is it used for? –Uri Jun 8 '14 at 10:41 3 This one works fine even in the latest Chrome, unlike @Matěj Pokorný's answer. weblink This returns an URL that can be used to retrieve the contents of the blob.
asked 6 years ago viewed 169163 times active 3 months ago Get the weekly newsletter! Data:application/octet-stream As you'll see sometimes with base 64 image files, having too much there can cause a strain on the client side. Label & Text-box alignment.
You could use this method and force a .click() on it, but watch the timing as Firefox doesn't like it if you call .click() before letting the element attach to the