24
Views
4
Comments
Audio Player with Configurable Controls?
Application Type
Reactive

Does anyone know of any audio player components that natively support rewind by x number of seconds? Seems like my only option at the moment is to code the whole audio player from scratch just to get that one feature. The expectation is that the rewind icon is inside the audio player controls.

2019-01-07 16-04-16
Siya
 
MVP

Which control or component are you using at the moment? You can achieve the rewind functionality using the JavaScript code below if your control is an HTML audio element:

function rewindAudio() {

    var audioPlayer = document.getElementById('audioPlayer');

    var rewindTime = 10; // Rewind by 10 seconds

    audioPlayer.currentTime = Math.max(0, audioPlayer.currentTime - rewindTime);

}


2022-11-14 17-25-57
Daniel Johnson

The JavaScript for the actions I'm OK with. I was just hoping there would be a component out there similar to like CK Editor where you can configure which controls are showing and it's already styled appropriately. In other words, the audio HTML element, just with more native control options.

2019-01-07 16-04-16
Siya
 
MVP

Please see if this helps : https://github.com/ableplayer/ableplayer

2022-11-14 17-25-57
Daniel Johnson

Thanks for the suggestion @Siya but I can't seem to get it to work. Can't get the audio player to load.

AblePlayer.oml
Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.