javascript - Link individual songs from mediaelement.js playlist -
javascript - Link individual songs from mediaelement.js playlist -
i'm using mediaelement.js playlist alternative , able create links individual songs. example, i'd utilize in codeigniter site briansukovez.com/audio/summertime/2 should play sec song.
i'm trying this:
$current = $this->uri->segment(3); echo "$(function(){ $('audio,video').mediaelementplayer({ loop: false, playlist: true, playtitle: $current,
but "playtitle" not working. i've looked @ mediaelement.js user guide , think should utilize play(). maybe play($current)? possible create easy?
where did find playlist or playtitle options in doc ?
you should utilize this, regarding link :
var player = new mediaelementplayer('#player', /* options */); // track number want play, current should number var current = <?php echo $current; ?>; player.pause(); player.playtrack($('.mejs-playlist li').eq(current)); player.play();
javascript codeigniter mediaelement.js
Comments
Post a Comment