Stream Your Music with Flash
There are many ways to serve up music on your website. You can offer it as a podcast, stream it with Quicktime, Real Media, even Windows Media. You can embed music as a page background in several formats. Or you can offer the music in a downloadable format via regular file transfer or BitTorrent. But, the easiest way to stream music is with Flash.
Flash offers a feature called Progressive Download. That means that your music will start playing as it is downloading. To do this without Flash you would normally need a streaming server. With Flash, your music will stream through your Flash player. This has two advantages. First, and believe me on this, Quicktime streaming is a royal pain to set up.
But the most important reason to stream with a Flash player is that your music will be more available to more people. If you use Quicktime, Real Media or Windows Media, your visitor will have to have the appropriate player installed. They will with Flash, too, but chances are very good that they have Flash installed already. Macromedia claims that over 96% of web browsers do. I like those odds.
Flash can handle several audio formats, but for web work mp3 works best. So, to start with you need to convert you music to mp3. I use iTunes. There are certainly more capable and sophisticated programs, but iTunes is easy to use and does a decent job. Since this is streaming web music it is probably going to play through computer speakers, which won’t play at audiophile quality anyway.
Following the same logic I use what Apple calls Good Quality encoding, 128 kbps. To set iTunes to import music this way, go to Preferences > Advanced > Importing. The settings are:

If you are using music that you’ve already imported, simply select the song and in the Advanced menu and chose Convert Selection to MP3. Even if it is already in mp3 format, iTunes will resample it to the Better bitrate.
Your song is now in your iTunes library. Unfortunately iTunes doesn’t want to export individual mp3 files to another folder, so you will have to get it manually. It’s in the ~/Home/Music/iTunes Music folder. If you ripped it from a CD, you’ll find it another folder under the artist’s name. If you used a single from another source it is under Unknown Artist. Or you can just search for the song using Find or Spotlight.
You will probably have to rename the music file with a web server friendly name by replacing spaces with an underline or dash. Ex = my_song.mp3 or my-great-song.mp3., but you already knew that.
If you want to use the entire song, you’re ready to upload it to your server. If you want to offer just a selection, you need to trim it. Again, there are lots of tools you could use. My favorite is a little shareware app called MP3 Trimmer. It makes it easy to trim a selection and can do fades, joins, and volume gain.
Okay, now you really are ready to upload. The other half of the process it to add a Flash player to your page so your visitor can enjoy your music. Of course, you can build your own Flash player. There are several tutorials to follow. There are also several ready made options that you can just drop in place. For free you might try: XSPF Music Player, FlamPlayer or the Hoover MP3 Player are three good choices. Since it’s pretty easy to create Flash players, there are lots of others available.
As with most programs, if you are willing to put out a few dollars you get more features and support. I’m a fan of the Wimpy Player, which I’ve used on a couple of sites. As of this writing, it comes is four versions, two that even play video. Try jazz singer Jenny Davis’ site for a one player per song example.
I have one request. Please include volume, or at least on/off controls with your music. All the players offer the option and consider it a service to your visitors to use them.
Which ever option you choose, the website should give you copy-and-paste code to embed the Flash player on your page. Enjoy.






3 Comments Add your own
1. flash web design | August 8th, 2006 at 1:31 am
Really nice articles for Flash professional like me.
Thanks a lot
2. Mac Web Design MacTheWeb &hellip | June 2nd, 2009 at 1:10 am
[...] Mac Web Design MacTheWeb Stream Your Music with Flash Posted by root 3 hours ago (http://mactheweb.com) Mar 26 2006 since this is streaming web music it is probably going to play through computer speakers 1 comment add your own 1 flash web design august 8th 2006 at 1 31 am designed by michael designs powered by wordpress Discuss | Bury | News | Mac Web Design MacTheWeb Stream Your Music with Flash [...]
3. Audiophile Speakers - spe&hellip | January 16th, 2010 at 10:12 pm
[...] [...]
Leave a Comment
You must be logged in to post a comment.
Trackback this post | Subscribe to the comments via RSS Feed