jacksorjacksor (Richard Jackson)
07/17/2024, 9:04 PMvar myMediaUrl = "/media/k3sd2q2z/myFile.pdf"
.
Intended use is for a Controller and/or button form submission (i.e. press the Download button, download the file).
Bonus points for having multiple media file URLs, compressing them all into one .ZIP file and downloading that .ZIP file.
TIA!
Rich
Umbraco v13Anders Bjerner
07/17/2024, 11:04 PMGetMediaByPath
is doing, so not entirely sure what validation is needed.
- Being a bit lazy, I hardcoded the mime type. You should probably write something to derive the mime type from the file extension.jacksorjacksor (Richard Jackson)
07/18/2024, 6:33 AMSebastiaan
07/18/2024, 7:25 AMAnders Bjerner
07/18/2024, 9:48 AMjacksorjacksor (Richard Jackson)
07/18/2024, 12:15 PMjacksorjacksor (Richard Jackson)
07/18/2024, 12:17 PMSebastiaan
07/18/2024, 12:49 PMjacksorjacksor (Richard Jackson)
07/18/2024, 2:02 PMhuwred
07/18/2024, 2:20 PMSebastiaan
07/18/2024, 2:51 PMSebastiaan
07/18/2024, 2:52 PMhuwred
07/18/2024, 3:01 PM