Radiant Media Player

Audio-only related content



Documentation sections


Features

Audio-only related content works very similarly to our video related content implementation so we advise first to review this area of our documentation before moving forward with audio-only related content.

Note that you cannot mix both video and audio-only content for related content. It has to be one or the other.

Video ads or audio ads can be played each time a new audio item is loaded within the player. The audio-only related content UI is fully compatible with mobile devices. A built-in error-recovery mechanism is also provided to skip audio related items that may be unavailable.

Supported audio-only streaming protocols are HLS, DASH and MP3/OGG/M4A progressive download. Other video related content features and restrictions generally apply to audio-only related content.


Audio-only related input data

The audio-only related content can be initialised by passing to the relatedLoc setting a URI to a JSON file holding audio-only related content data. You will also need to set relatedAudioOnly player setting to true. Here is a full example of a well-formatted JSON file that can be used for input to audio-only related content.

Read our general related documentation for a guide to JSON files compatible with our audio-only related content.


Audio-only related content settings

relatedAudioOnly: Boolean

This enables audio-only related content layout required to properly display a list of audio-only content. Default: false.

Other settings for video related content also apply for audio-only related content


Audio-only related content code example - see this example live here

The below code is used to display the audio-only related content example provided above:

Take note of the additional div elements required to display the audio-only related content UI.

<script src="https://cdn.radiantmediatechs.com/rmp/5.10.6/js/rmp.min.js"></script>
<!-- Here is our specific markup for audio-only related content -->
<div id="rmpPlayer"></div>
<script>
var settings = {
  licenseKey: 'your-license-key',
  // if you want ads to show uncomment this next setting
  // ads: true,
  // our related content settings
  relatedUpNextOffset: 10,
  relatedUpNextAutoplay: true,
  relatedEndedLoop: false,
  relatedLoc: 'https://www.radiantmediaplayer.com/media/playlist/audio-only/audio-related-hls.json',
  // our audio-only related content setting
  relatedAudioOnly: true
};
var elementID = 'rmpPlayer';
var rmp = new RadiantMP(elementID);
rmp.init(settings);
</script>

The video related content API & events also applies to audio-only related content.


Additional support notes

The support notes for video related content also apply to audio-only related content.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 3.0 License.