mp3 files are not being downloaded as original filenames, "filename.mp3", but instead as song names "songname", without the extension suffix. this happens only on desktop firefox 78.0.1 (64-bit). firefox on mobile also downloads files without extension (mp3).
Can you please make some change to the code so it would add the ".mp3" extension to the end of the downloaded file name, if the extension is not present?
Im not 100% certain but i think that the browser automatically add the extension itself depending which browser you are using. Once the file is saved, do you have a mp3 extension if you browse your file with explorer ?
this is an issue only in firefox, and it is also happening in firefox mobile versions. The file, once it is saved is still just "songname" and not "songname.mp3" unfortunately. This is strange - your plugin should serve files with extensions, and it works with chrome, but fails on firefox. If I browse the file directly, yes I do have the extension, and all files are presented to the plugin as "external links" all leading to mp3 files, saved as "songname.mp3" "songname2.mp3" etc - all the files on the server have mp3 extensions, and the plugin is given links with full mp3 extensions too, and chrome is downloading them correctly with .mp3, but it's only firefox that just downloads files as plain files, without any extension at all. Can this be fixed please?
mp3 files are not being downloaded as original filenames, "filename.mp3", but instead as song names "songname", without the extension suffix. this happens only on desktop firefox 78.0.1 (64-bit). firefox on mobile also downloads files without extension (mp3).
WHAT IS YOUR URL?
Thanks,
Max from the Sonaar.io Crew
https://h-var.com/album/2015-psychectomia/
The name of the file will be the trackname.
If your filename is called abc.mp3 but your tracktitle is xyz, the file downloaded will be xyz
Thanks,
Max from the Sonaar.io Crew
Can you please make some change to the code so it would add the ".mp3" extension to the end of the downloaded file name, if the extension is not present?
Hi,
Im not 100% certain but i think that the browser automatically add the extension itself depending which browser you are using.
Once the file is saved, do you have a mp3 extension if you browse your file with explorer ?
Thanks,
Max from the Sonaar.io Crew
this is an issue only in firefox, and it is also happening in firefox mobile versions. The file, once it is saved is still just "songname" and not "songname.mp3" unfortunately. This is strange - your plugin should serve files with extensions, and it works with chrome, but fails on firefox. If I browse the file directly, yes I do have the extension, and all files are presented to the plugin as "external links" all leading to mp3 files, saved as "songname.mp3" "songname2.mp3" etc - all the files on the server have mp3 extensions, and the plugin is given links with full mp3 extensions too, and chrome is downloading them correctly with .mp3, but it's only firefox that just downloads files as plain files, without any extension at all. Can this be fixed please?
Please unzip the file attached and replace your old file by this one.
The file is located in sonaar-music/includes
Thanks,
Max from the Sonaar.io Crew
Thank you! This solution works perfectly with
$download = ' download'; instead of $download = ' download="' . $track['track_title'] . '"'; !
Thank you so much! Files now downloading with extensions!