Adding Players
MP3-jPlayer works with all of the media features built into WordPress, you can use any method available in your WordPress install to add players, including the new playlist builder introduced in WordPress 3.9.
Additionally you can write shortcodes, use widgets, and automatically replace links with players.
Here’s 5 different ways that you can add players into your pages.
1. Paste the URL
From WordPress 3.6 you can simply paste a url into your page content, put it on a fresh line, for example this url:
http://sjward.org/seven.mp3
produces a single-file player like this:
2. Use the ‘Add Media’ button
Upload your audio into the media library first, then go to one of your post edit screens and click the ‘Add Media’ button.
Choose a file and click ‘Insert Into Post’. If you use WordPress 3.9 or later, then you’ll be able to build playlists very easily by choosing ‘Create Audio Playlist’ from the left hand options. Here’s an example playlist:
When you do this you’ll see that WordPress inserts a shortcode into your post, something like this:
[playlist ids="17,82,80"]
3. Use a Widget
Put players in your sidebars, see the Widgets Page for more info.
4. Write a Shortcode
You could modify the shortcode above if you wanted with various settings, for example you could shuffle the list:
[playlist ids="17,82,80" shuffle="y"]
Or just write your own shortcodes, for example this one plays one of my library tracks, and a url:
[playlist tracks="Fireheart.mp3, http://sjward.org/seven.mp3"]
Or make a popout player button, that auto-plays when launched:
Launch Popout Player
[popout tracks="Fireheart.mp3" autoplay="y"]
For more examples on using shortcodes in general, please see the Demo pages.
5. Automatic Link Replacement
Add a link to an audio file into your page or post and MP3-jPlayer will replace it with an audio player for you, you can do this with the ‘Add Media’ button or if you use the ‘Text’ editor then you can write them straight into your page like this:
<a href="http://mp3-jplayer.com/wp-content/uploads/dolfinarium.mp3">Dolfinarium</a>