With the release of Radiant Media Player 5.3.0, we now offer audio playlist support (audio-only content). This works very similarly to our video playlist implementation so we advise first to review this area of our documentation before moving forward with audio playlist.
Video ads can be played each time a new audio item is loaded within the player. The audio playlist UI is fully compatible with mobile devices. A built-in error-recovery mechanism is also provided to skip audio playlist items that may be unavailable.
Supported audio-only streaming protocols are HLS, DASH and MP3/OGG/M4A progressive download. Other video playlist features and restrictions generally apply to audio playlist.
The audio playlist can be initialised by passing to the playlistLoc
setting
a URI to a
JSON file holding audio playlist data. You will also need to set
playlistAudioOnly
player setting to true.
Here
is a full example
of a well-formatted JSON file that can be used for input to an audio playlist.
Read our general playlist documentation for a guide to JSON files compatible with our audio-only playlist content.
playlistAudioOnly: Boolean
This enables audio playlist layout required to properly display a playlist
of
audio-only content. Default: false
.
Other settings for video playlist also apply for audio playlist
The below code is used to display the audio playlist example provided above:
Take note of the additional div elements required to display the audio playlist UI.
<script src="https://cdn.radiantmediatechs.com/rmp/9.15.16/js/rmp.min.js"></script> <!-- Here is our specific markup for playlist --> <div class="rmp-playlist-container"> <div class="rmp-playlist-player-wrapper"> <div id="rmp"></div> </div> </div> <script> const settings = { licenseKey: 'your-license-key', // if you want ads to show uncomment this next setting (ad data for each playlist item can be passed in JSON file) // ads: true, // our playlist settings playlistUpNextAutoplay: true, playlistEndedLoop: false, playlistLoc: 'https://www.radiantmediaplayer.com/media/playlist/audio-only/audio-playlist-hls.json', // our audio playlist setting playlistAudioOnly: true }; const rmp = new RadiantMP('rmp'); rmp.init(settings); </script>
The video playlist API also applies to audio playlist.
The support notes for video playlist also apply to audio playlist.
©2015-2024 Radiant Media Player. All Rights Reserved.