Menu
Here is my code that forces the download of a mp3- file from another server.
[CODE]<?php
$mp3 = “http://www.mysite.com/song.mp3”;
header(“Content-Disposition: attachment; filename=$mp3”);
header(“Content-Type: audio/mpeg”);
readfile($mp3);
?>
The problem is that the filename is the entire URL when downloading this file, and I want it to be shorter.
(e.g. http___www.mysite.com