|
Posted by ZeldorBlat on 03/14/07 15:37
On Mar 14, 10:56 am, "lawrence k" <lkrub...@geocities.com> wrote:
> I want files like this to download, rather than play in people's
> browsers:
>
> http://www.monkeyclaus.org/media/audio/abel_okugawa/816_mix/trumpethe...
>
> Can I fix this with a directive in an .htaccess file? If not, suppose
> I serve it through a php file that opens the file and reads and
> streams it to the requesting browser. Is there some header I could
> sent with the header() function that would force a download? Would I
> be breaking the internets if I sent a long an unknown mime-type just
> to force a download?
You can usually force a download with the following header:
header('Content-Disposition: attachment; filename=somefile.mp3');
More info can be found here:
<http://www.google.com/search?q=force+download>
Navigation:
[Reply to this message]
|