...

View Full Version : store music - need hint where to get started



webjoker
01-04-2012, 11:09 PM
Hello there,

I have a small problem. I want to store some music and let people who visit my website to hear the music when they press a "play" button. But the problem is, i have no idea where to start from. The only thing i know is that, i need a form in my html, where i create the button i guess? And i'm gonna use a database (MySQL) which is gonna include the artist name and the playtime etc. But other than that, i have just no idea.

So i was wondering if you guys maybe could help me get started with this, maybe give me a hint? I was putting it in this part of the forum because i suppose, most of the code will be PhP code.

Well i really hope i can get some help out there. This is a school project and will be done in about 3 weeks, so i just want help to get started with this part. I know i'm not very good at webprogramming yet but i love doing it and perhaps i will become good one day. I would really appreciate some help. :)

mlseim
01-05-2012, 12:44 AM
If your music is MP3 ... you can use a free Flash MP3 player embedded in your website.
There are several to choose from. What you do is store the actual MP3 files in a directory,
and then store the MP3 filenames in the database.

Here is a link to a free MP3 Flash Player:
http://www.catpin.com/streaming.php
Test it out and download the zipped .swf (flash) file.

Here is an example of how to play an MP3 file called "your_song.mp3"
using the "streaming.swf" file that you unzipped. You need to enter the
path and filename of your own MP3 files (of course).





<object type="application/x-shockwave-flash" data="player.swf" width="290" height="24" id="audioplayer1"><param name="movie" value="player.swf" /><param name="FlashVars" value="playerID=1&amp;bg=0xf8f8f8&amp;leftbg=0x8297cc&amp;lefticon=0xffffff&amp;rightbg=0xe09e7b&amp;rightbghover=0xb35884&amp;righ ticon=0xffffff&amp;righticonhover=0xffffff&amp;text=0x666666&amp;slider=0x666666&amp;track=0xFFFFFF&amp;border=0x666666&amp; loader=0x9FFFB8&amp;soundFile=your_song.mp3" /><param name="quality" value="high" /><param name="menu" value="true" /><param name="bgcolor" value="#FFFFFF" /></object>




.

webjoker
01-05-2012, 06:29 PM
If your music is MP3 ... you can use a free Flash MP3 player embedded in your website.
There are several to choose from. What you do is store the actual MP3 files in a directory,
and then store the MP3 filenames in the database.

Here is a link to a free MP3 Flash Player:
http://www.catpin.com/streaming.php
Test it out and download the zipped .swf (flash) file.

Here is an example of how to play an MP3 file called "your_song.mp3"
using the "streaming.swf" file that you unzipped. You need to enter the
path and filename of your own MP3 files (of course).





<object type="application/x-shockwave-flash" data="player.swf" width="290" height="24" id="audioplayer1"><param name="movie" value="player.swf" /><param name="FlashVars" value="playerID=1&amp;bg=0xf8f8f8&amp;leftbg=0x8297cc&amp;lefticon=0xffffff&amp;rightbg=0xe09e7b&amp;rightbghover=0xb35884&amp;righ ticon=0xffffff&amp;righticonhover=0xffffff&amp;text=0x666666&amp;slider=0x666666&amp;track=0xFFFFFF&amp;border=0x666666&amp; loader=0x9FFFB8&amp;soundFile=your_song.mp3" /><param name="quality" value="high" /><param name="menu" value="true" /><param name="bgcolor" value="#FFFFFF" /></object>




.

Oh, thank you very much! I will take a look at your code you just gave me and try it out. It means really much to me! Oh, and have a nice day :)

Regards: Webjoker

webjoker
01-05-2012, 11:00 PM
Oh i have another question! Do it work fine with Windows media player aswell or do i have to download a flash player? :)

mlseim
01-05-2012, 11:18 PM
I thought you wanted to have them play it on the website.

If you want them to be able to download it, then you can do that too.
They would be downloading an MP3 file, just like any other MP3.
Your music is in the form of MP3?

It's all the same. You put your MP3 files in a directory, and the filenames in the database.
Instead of the embedded Flash Player, you have a link to download each song.

That's a pretty good starting point for you ...
You said school project ... is it homework?

webjoker
01-05-2012, 11:31 PM
Should say more or less a project, been having this for several months now, or, you could also see this as a homework therefore i don't work with this website at school. And at the same time i'm going to make this website for my dad, he's in need of one. I'm going to kill two birds with one stone. :)

webjoker
01-06-2012, 11:54 PM
Oh forgot to thank you, i made it. Now, it is possible to listen too music at my webpage. Really appreciate your help!

mlseim
01-07-2012, 12:52 AM
And there are other free Flash Players.
Some even have playlists. You can Google: Free MP3 Flash Players


.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum