Streaming Audio: m3u -> mp3
Steven Elling
ellings at kcnet.com
Thu Nov 21 20:42:18 CST 2002
On Thursday 21 November 2002 14:06, Greg Kedrovsky wrote:
> Has anyone had any experience with mp3s on web sites? I have a slight
> problem.
>
> http://www.greg-and-sue.com/mp3_test.htm
>
> That's the test link and it does what all other links to m3u files do in
> my Opera browser, and in the browser my Dad uses on his Mac G4 OS/X. You
> click it, and instead of playing the mp3 file the m3u link points to,
> you get the m3u text file printed out in your browser screen.
>
> m3u files worked fine for me under M$ WinDoze Internet Explorer. Is this
> an MS specific trick (the m3u)?
>
> My intention is to get streaming audio. Click the link, a WinAmp or XMMS
> player will crank up the mp3 and play it as it downloads. Can I do that
> outside the world of MS Internet Explorer?
>
> Thanks.
> -Greg
I've set up a streaming MP3 server before. The problems arises in the HTTP
headers passed back to the browser. In your case, your Apache/1.3.20
server sends back a 'Content-Type' header of 'text/plain'. The browser
reads the header a determines that it can display this MIME Type directly
so it does.
What I had to do to get eveything to play nicely is to pass back a
'Content-Type' header of 'audio/mpegurl'. If you implement a CGI script to
build the m3u file on the fly, sending back a 'Content-Disposition' header
of 'filename=playlist.m3u' would also be beneficial.
More information about the Kclug
mailing list