[nycphp-talk] header to force helper app for MP3 file
Jerry Kapron
nyphp at NewAgeWeb.com
Fri Jun 18 13:14:34 EDT 2004
Stephen,
To force the browser to show the Open/Save dialog box, in addition to the
Content-Type header you should send the Content-disposition header:
'Content-disposition: attachment; filename=filename.mp3'
Cheers,
Jerry
-----Original Message-----
On Friday, June 18, 2004 11:46 AM Stephen Musgrave wrote:
>
>from browser to browser, platform to platform, there are varying scenarios
>that a user is put through when clicking on an MP3 file. on my mac a new
>page opens with quicktime embedded in the middle and the file plays. on
one
>PC that it was tested on, windows media player launched.
>
>i've tried to use various header directives which cause, again, varying
user
>experiences a couple that i have tried include:
>
>- - - - - - - -
>
>header('Content-Type: application/mpeg');
>readfile($filename);
>
>- - - - - - - -
>
>header('Content-Type: audio/mpeg');
>readfile($filename);
>
>- - - - - - - -
>
>header('Content-Type: audio/x-mpegurl');
>readfile($filename);
>
>- - - - - - - -
>
>i want the user's helper application for mp3s to launch. if there isn't
one
>defined, they should be prompted to decide to choose one or download.
>
>any tried and true method?
>
>thanks much : stephen
>
>
>_______________________________________________
>talk mailing list
>talk at lists.nyphp.org
>http://lists.nyphp.org/mailman/listinfo/talk
>
More information about the talk
mailing list