Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   Winamp Discussion (http://forums.winamp.com/forumdisplay.php?f=8)
-   -   M3U playlist - read article - still doesn't work (http://forums.winamp.com/showthread.php?t=226464)

pjkinann 20th September 2005 05:40

w3U playlist - read article - still doesn't work
 
I'm new to this forum, and this may be the incorrect place to post this, but I tried posting in a general area and it said I didn't have permission to post there. This was as close as I could get to posting somewhere. My account was just activated, so that may have something to do with it.

I've been searching for days on "how to" create an m3u list and make it work!

The URLs that I found have explained that it's quite simple. This is what you put in Notepad (for example):
http://www.domain.com/music/song.mp3, then save the text file as an m3u file. (that's not a real link - it's a sample link)

Then the link in the html is supposed to be like this, for example:
< a href="/music/song.m3U">Listen</a>

Well, I've tried that numerous times, and nothing ever happens except I get an error message saying it can't be found.

So I must be doing something incorrectly to get these m3U link to work.

My m3U playlist is in the same folder as the audio.

I'd post my page for you to look at but some forums don't allow you to do that.

IF someone can direct me to the correct forum where I can get some help on figuring out how to get some audio files to work through an m3U list, I'd really appreciate it.

Thanks
pjkinann
pjkinann@aol.com

billyvnilly 20th September 2005 06:22

...what article did you read exactly? :weird:

anyways
try this link: http://forums.winamp.com/showthread....threadid=65772

I'm also curious as to why you want to manually create it...when you could just make it in winamp and save it.

pjkinann 20th September 2005 06:33

Yes, I had read the link that you mentioned, and found it very confusing for someone who has never done this before.

The actual article I found which explained it pretty simply:
http://www.developingwebs.net/html/mp3.php; http://www.mickwood.com/articles/streaming.shtml; http://www.samisite.com/test-csb2nf/audio.htm - but even following those instructions mine just does not work.

Why don't I use WinAmp? I don't know how to use it. :( And I didn't want to have to learn a complete new software just to finish this site for the client.

So I really am not understanding why this doesn't work.

DJ Egg 20th September 2005 14:30

A simple .m3u can just contain direct links to the files you want to stream.
Each file must be listed on a new line, eg.

http://site.com/dir/file1.mp3
http://site.com/dir/file2.mp3
http://site.com/dir/file3.mp3
etc etc etc

If there's any spaces in the filename, then it is recommended to replace them with %20 (html code for a space), eg.

http://site.com/dir/this is the file.mp3
becomes
http://site.com/dir/this%20is%20the%20file.mp3


Basically, open Notepad
Type/paste in the full paths for each file on a new line
Go to: File menu > Save As
Change the "Save as Type" drop-down menu to "All files" (not the default .txt)
Type in the desired filename, eg. playlist.m3u
Save the file and upload it to the server
Then link to it in your html as normal, eg.

<a href="http://site.com/dir/playlist.m3u">Listen</a>

If you want to create an Extended .m3u, then you can add extra fields.
These extra fields simply help whatever application is loading the playlist to read the metadata/id3 tags of each file a bit quicker. But the extended info is not esssential/required.

Using the simple .m3u example from above, the extended .m3u would look like:

#EXTM3U
#EXTINF:-1,Artist1 - Title1
http://site.com/dir/file1.mp3
#EXTINF:-1,Artist2 - Title2
http://site.com/dir/file2.mp3
#EXTINF:-1,Artist3 - Title3
http://site.com/dir/file3.mp3

Where "#EXTM3U" is the file header which tells the application it's an m3u playlist.
Where "#EXTINF:" is the Extended Info header for each file to be streamed.
Where "-1" is the playing time of the file

-1 is commonly used when streaming, though if the m3u was stored on a local hard drive for personal/non-streaming usage, then you could put the actual track time here, eg. #EXTINF:180, where 180 = 180 seconds (3 minutes)

And where "Artist1 - Title1" is the Artist and Title tags found in the metadata/id3 tags for said file.

Though, like I said, the ExtInf is not essential/required.

pjkinann 20th September 2005 19:55

Thank you so very, very much for explaining that in such great detail. I thought that is what I had done, but I'm going to go through what you've explained and recheck my work and see if I can get it work this time.

Q. Does this work on ANY server? I'm wondering if my server doesn't handle m3u's or something?

But I'll do what you have instructed and see if it works.

THanks again.
PJ

pjkinann 20th September 2005 20:15

Yeah, see, here is a site that utilizes the m3U playlist but they just have it where you click on the name of the song and it plays - quickly too.
http://www.reachchaya.com/music.html

DJ Egg 20th September 2005 21:44

yeah, you might need to set the mime-type on the server

MIME for m3u is: audio/mpegurl


It depends on what type of server, eg.


Apache/Unix servers use a .htaccess file to configure MIME

AddType . audio/mpegurl . .m3u


Wheras other servers use a mime.types file to configure MIME

audio/mpegurl . .m3u


All times are GMT. The time now is 07:34.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.