Audio Player Wordpress plugin
If you wish to make a donation to the author of the Audio Player plugin (that’s me), use the Paypal button.
Audio Player 2.0 beta is now available!
Table of contents
If you want to use this player on a non-WordPress site, Mindy McAdams has written a very detailed tutorial here.
Important note: This plugin only works in posts and pages. It does NOT work in headers, sidebars or footers and I do not provide support for placing it there.
Other important note: This plugin only plays MP3 files. This is a limitation of the Adobe Flash Player.
Contents Usage
Once installed, this plugin allows you to insert mp3 audio files into your posts and pages. Use the following syntax:
[audio:name_of_mp3_file.mp3]
This code will insert a flash player and will load the file named name_of_mp3_file.mp3 located in your audio files folder. You can store your audio files anywhere in the web root as long as you update the path in the plugin’s options panel. The default is /audio.
You can also use absolute paths to link to files on other servers:
[audio:http://www.somedomain.com/path/to/name_of_mp3_file.mp3]
Audio Player can also play a sequence of audio clips. Use commas to separate the files:
[audio:name_of_mp3_file1.mp3,name_of_mp3_file2.mp3,name_of_mp3_file3.mp3#093;
You can also pre-append and post-append a clip to all your players. Explained in the Podcasting section.
Contents Examples
Default colour scheme
Custom colour scheme
Contents Podcasting
If you are using the player for a podcasting blog, Audio Player has special options just for you.
Enclosures
If you are unsure what an enclosure is, read the definition on Wikipedia. You have 3 options:
[audio] syntax but you must use absolute URLs:
e.g. http://www.somedomain.com/path/to/name_of_mp3_file.mp3
WordPress will automatically detect the file and set the relevant enclosure option for you.
Pre/Post appended clips
You may wish to pre-append or post-append audio clips into your players. To do this, enter the full urls in the relevant section of the options panel. The pre-appended audio will be played before the main audio, and the post-appended will come after. A typical podcasting use-case for this feature is adding a sponsorship message or simple instructions that help casual listeners become subscribers. This will apply to all audio players on your site. Your chosen audio clips should be substantially shorter than your main feature.
Contents RSS Feeds
You have a choice over what to show in your RSS feed:
Go to the options panel to set these options.
Contents The “chipmunk” effect
The Macromedia Flash player has a problem playing files that are encoded at a rate that is not a multiple of 11.025 kHz. This effect is sometimes called the “chipmunk†effect: the file is played at double speed. To avoid this, encode MP3s at 11.025 kHz 22.050 kHz or 44.100 kHz.
Contents Colour scheme
The entire player colour scheme is customisable. Use the Audio Player options panel in your WP admin to set the colour scheme of your player. You can also change the colours per player instance by using runtime options. Here are the colours that you can set:
![]()
Contents Runtime options
Use these if you want to use a different colour scheme for a particular player instance. You can also make the player open automatically or loop the loaded clip. You can pass a number of options to a player instance. To do this use the following syntax:
[audio:name_of_mp3_file.mp3|option1=value|option2=value]
Example:
[audio:name_of_mp3_file.mp3|autostart=yes|bgcolor=0x000000]
This will set the main background colour of the player to black and automatically start the player when the page loads.
Contents Installation
You should end up with this folder structure:
I recommend an
audio folder in the root of your blog so it doesn’t interfere with your WP install. If you wish to use another folder, remember to change the audio files directory option on your options panel. Activate the plugin in your WP admin Go to Options > Audio Player in the WP adminHere, you can choose how you want to use Audio Player and also set the colours to match your site’s design.
Contents Upgrading from 0.x to 1.x
Once installed, the old player is overwritten with the new one and all colour options should be transfered to the new scheme. Some adjusting to the slider and loader bar colours might be necessary.
Contents Upgrade wizard
Audio Player comes with an upgrade wizard. On the options panel, you can find out if a new update is available by clicking the Check for updates button. If an update is available, you will be prompted to open the upgrade wizard. Simply click Upgrade and the wizard will download the latest version and install it for you. Note: The upgrade wizard relies on some PHP functionality that is not available on all server configurations. You host may have disabled these features, in which case the upgrade wizard will be disabled.
Contents Change log
1.2.3 (4 September 2006)
1.2.2 (14 February 2006)
<a> tags1.2.1 (12 February 2006)
<a> tags)1.2 (07 February 2006)
1.0.1 (31 December 2005)
1.0 (26 December 2005)
0.7.1 beta (29 October 2005)
0.7 beta (24 October 2005)
0.6 beta (23 October 2005)
0.5 beta (19 October 2005)
/audio folder Better handling of paths and URIs Added support for linking to external files
June 28th, 2008 at 3:13 am
@Cynosure, php works in .htm and .html files but I am not sure how you get it to work in a non-wordpress environment. The plugin is meant to be activated within Wordpress’ dashboard/admin.
#2849: Cynosure Says:June 28th, 2008 at 1:43 am
Sorry, I should have said that I am not using this with Word-Press. I am using it with a regular website. I don’t use a php file to call the script. I use html. Is that what is causing the problem?
#2848: myhnet Says:June 28th, 2008 at 1:33 am
hi,
I download your lasted version, but seems problem with it.
after I extract the audio-player.1.2.3.zip, I got a suberdirectory also named audio-player and almost all the files are in it, but it didn’t work after I move the files in it to the root directory of the plugin and modify the file named audio-player.php :
change
include( “audio-play/options-panel.php” );
to
include( “options-panel.php” );
pls check it,thx
#2847: Cynosure Says:June 28th, 2008 at 1:18 am
I have installed your script on my site, but everytime I click to tart or stop the playing I get an error. It still works fine, but firefox show this error in the bottom:
ap_stopAll is not defined
What can I do to fix this?
#2846: Helene Says:June 27th, 2008 at 11:16 pm
First, thanks for this player!
#2845: mike Says:Then: Mindy McAdams says you can use several mp3 files for one player, but i really don’t understand how!!! If it is possible, please let me know…
Thank you.
June 27th, 2008 at 11:33 am
Great work !!!
Is it possible to enable display of the player not in the post, but in the wordpress header using the header template ?
If yes, what is the code i need to use? I gess a PHP call.
Tanks.
#2844: Dan Says:June 25th, 2008 at 2:57 pm
I don’t know what happened but I downloaded version 1.2.2…
I loaded 1.2.3 and it’s working fine. Thanks!
#2843: Dan Says:June 25th, 2008 at 2:46 pm
A preview of the player is also not showing up in the options window under the colour scheme section…just the “block”
Am I having some other problem with player.swf?
#2842: sincinaty Says:June 25th, 2008 at 11:58 am
Hi, at first thanks for the great player!
On my page http://www.sincinaty.de in the categorie “musik” i added about 10 audio player (v 1.2.3). The problem is, that the cpu usage on slower pcs goes up to 100%, when the music page is loaded.
I replaced the audio-player.swf file with the new one (v2 beta) the cpu problem was solved, but now the stop function wasn’t available any more.
This means, when I started 5 players, each player plays his mp3…. so i have noise.
Is there any possibility to add the stop function to the new player?
I mean, in the *js document, there is the stop function, but the new player doesn’t react on this!
Thanks, Sin!
#2841: kelly Says:June 25th, 2008 at 7:43 am
Vic I’ll see if I can find the info for you.
Dan, where’s the page where the code is? It’s possible the colours are the same as your background page so you don’t see it. ? >,<