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.
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);
}
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.
Please see if this helps : https://github.com/ableplayer/ableplayer
Thanks for the suggestion @Siya but I can't seem to get it to work. Can't get the audio player to load.