Embed Online MP3 Player In Your Website, Fast & Easy

Posted in howto, webvideo


Make Crisp Clear Video Others Envy!
OR
We Make Them For You...Plus More!

« How To Use Gadwin’s Free Screen Capture Software  |  Web Marketing For Small Business – What’s Hot? »

   

If you want a hassle-free, free mp3 player to embed any online audio in your website, you can try StangeCube’s AudioPlay.

AudioPlay is based on flash technology, and all you need to run your favorite music or podcast in your blog is to embed some html codes therein. Of course you have to have the music to be embedded already available on the net.

Watch the video below on how to go about. You may also see it on YouTube.

 

Download AudioPlay

You may use AudioPlay in 2 ways. Download the free codes in a zip file from their website. The present version is 0.9.9 released as on 20.10.2010 (see following image).

Download the mp3 player, AudioPlay

After you’ve downloaded and unzipped the contents, you’ll find 4 files and a folder. The folder contains the images of buttons of different designs (see following image).

 

These AudioPlay files are to be uploaded for embedding mp3

Among the files, the audioplay.swf file is responsible for ‘driving’ the audio player. The config.xml file is where you can change the different parameters for altering the playing of audio. For example, you can delay the start of the audio while making it automatic; you can make the audio fade in and control its volume; you can let the mp3 audio repeat as many times or infinitely, and so on.

You can embed several mp3 players in a single webpage. In that case each player will be having a distinct identification, like ‘playerid=1’, ‘playerid=2’, and so on. The XML file will contain the path to the location of the mp3 file for each player. Take a look at the following piece of code.

<player playerid="2">
<musicfile>music.mp3</musicfile>
<repeatTimes>1</repeatTimes>
<autostart>no</autostart>
<buttondir>buttons/classic</buttondir>
<mode>playpause</mode>
<sendStop>yes</sendStop>
<listenstop>yes</listenstop>
<trackid>second</trackid>
<fadeindur>1000</fadeindur>
<mastervol>90</mastervol>
<autostartdelay>1000</autostartdelay>
<einterface>yes</einterface>
<initbuf>no</initbuf>
</player>

From the index file you’ll know the html embed code which is what you will need to embed the mp3 player in your website or blog. The html code is likely to be as under. Refer this article to know more on embedding SWF flash file.

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/
flash/swflash.cab#version=10,0,0,0" width="30" height="30"
id="player2">
<PARAM NAME=movie VALUE="audioplay.swf?playerid=2">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=wmode VALUE="transparent">
<PARAM NAME="allowScriptAccess" value="always" />
<embed wmode="transparent" src="audioplay.swf?playerid=2" quality=high width="30" height="30" name="player2" allowScriptAccess="always"
align="" TYPE="application/x-shockwave-flash"
pluginspage="http://www.macromedia.com/go/getflashplayer">
</embed>
</object>

Notice, in the above html code, the reference to the mp3 audio is via the playerid parameter. In this
case it is playerid=’2’.

Once you know the purpose of the different files, the next action will be to upload the files to your web server. In particular, you should upload the button images (of the style you choose), the config.xml, the audioplay.swf file, and the mp3 file of the audio you want to embed.

The html code to embed mp3 player is given above.

 

Auto-Generate Code To Embed MP3 Player

Many of you may not feel comfortable to play around with codes. For them, the solution is to use the excellent online code generator provided by StrangeCube AudioPlay (see the following image).

AudioPlay online code generator for embedding mp3 player

All you need to do is to mention the absolute URL of the MP3 file to be embedded, select some of the choices like repeat, button style, player mode, etc., and then press the Generate Code button. The html code for embedding the mp3 player comes in the small box on the right.

Copy it and paste it in your blog where you want the player button to come. And there you are! Your favorite mp3 is now ready to be played.

As way of demonstration I have embedded the following button which is the mp3 player to play the audio narration of this article when clicked. Try it out.

You may like to read the following related articles:

  1. Easily Transfer Embedded Audio In PowerPoint Presentation
  2.  

  3. 2 Easy Ways To Embed Podcast Player In Your WordPress Blog
  4.  

  5. How To Embed Audio Clip In PowerPoint 2010
Get the latest top web marketing tips! 'Like 2WebVideo' now on Facebook below!

This article of April 16th, 2011 is authored by Partha Bhattacharya, who runs this website. Partha also creates video-based e-learning course for clients, and when time permits, writes guest articles for selected sites.

7 Comments

  1. I forever wanted to know about this, thankyou for posting . I also think hence , perfectly indited post!. We want some of the articles from your blog with a link.

  2. Has anyone tried uploading the files for AudioPlay 0.9.9 (20.10.2010) to website as described above? I cant make it work!

    Ive downloaded the files and placed them as described at http://www.strangecube.com/audioplay. Everything works well locally on my pc, but when i upload it to server AudioPLay is not visible any longer!

    Ive tried everything possible:
    embedding with SWFObject 2.0 and through Dreamweaver,
    ive added doctype to downloaded HTML test-page, corrected HTML-code where ” were needed ..still not working!

    My server / website plays other SWF’s, except for the one from AudioPlay. Did anyone test the downloadble files on a server?

    You can take a look at the code and the (missing) result of upload of AudioPlay at http://www.byenshjemmesider.dk/ for a few more days untill i give up.

    There are one pink box and 3 items present at the page:
    The pink box contains the code from the downloaded files. Its empty..
    Item 1. Audioplay embedded with the code from online generator as described above. That works.
    Item 2. A different flash / SWF-based mp3player. That works.
    Item 3 A graphic SWF with movement. That works

    I really do like the mp3 player and how easy it can be customized.

    Can someone verify that the files downloaded from AudioPlay 0.9.9 (20.10.2010) is working when they are uploaded?

  3. Did anyone make the files from AudioPlay download work once uploaded to a website?

  4. @Henry, I empathize with you. Checked your page…the code is very confusing.

    The first thing may be to remove all unnecessary codes, and keep the embed code for just one player.

    You may also consider having the audio button in a separate page, and then embed it anywhere you want with <iframe> </iframe> tags as I’ve done at the end of the article above.

    Best of luck!

    • My mistake; AudioPlay is working fine once uploaded!
      I modified the original buttons, and only uploaded the buttons that i wanted to use in my setup.

      To make AudioPlay work you must UPLOAD ALL BUTTONS from the directory that you will be using to store buttons in (fx “classic”):
      If you didnt upload fx “playdown”, AudioPLay will stop working!

      You can check code and modified buttons (working now) at http://www.byenshjemmesider.dk/.
      Note that the moving graphic is another SWF placed underneath the modified “to-be-seen-through” AudioPlay “stopup” button

      • @Henry, good it worked for you! :)

  5. paylasim icin tesekkurler elinize saglik. harika bir site.

Trackbacks/Pingbacks

  1. How To Create An Overlay Lightbox In Your Webpage « Mukut Saha - [...] Embed Online MP3 Player In Your Website, Fast & Easy [...]
  2. How To Create An Overlay Lightbox In Your Webpage « Mukut Saha - [...] Embed Online MP3 Player In Your Website, Fast & Easy [...]

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>