Timeline for How do I download a JPG file from the server?
Current License: CC BY-SA 3.0
5 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Nov 26, 2018 at 13:51 | comment | added | Alfred Armstrong | You can't do this in AJAX, the simplest solution will be for the button to be an ordinary link which points to the download callback as above. | |
Jan 3, 2013 at 9:16 | comment | added | David Thomas | Ah ok, perhaps you could use a direct link to the file instead of the ajax callback? e.g hook menu with filename parameter or similar. With the same handler, it should serve the file for download. | |
Jan 3, 2013 at 9:06 | comment | added | Kiran Kumar | The above solution doesnt work in ajax call, any further help? | |
Jan 3, 2013 at 7:26 | comment | added | avpaderno♦ | Does it work for an AJAX call? Notice that the OP is using the "wrapper" property, and what returned from the AJAX callback replaces what is present in the wrapper. | |
Jan 3, 2013 at 7:21 | history | answered | David Thomas | CC BY-SA 3.0 |