Created
September 30, 2013 14:38
-
-
Save dyaa/6764748 to your computer and use it in GitHub Desktop.
#jplayer display the current song name in the main box
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var myPlaylist = new jPlayerPlaylist({ | |
//then this will capture the current song's title: | |
//myPlaylist.playlist[myPlaylist.current].title | |
//For instance, I used this to capture the current song's title and insert it into a div on my page with id 'current-track': | |
var myPlaylist = new jPlayerPlaylist({ the playlist }); | |
$("#jquery_jplayer_1").bind($.jPlayer.event.play, function(event) { | |
$('#current-track').empty(); | |
$('#current-track').append(myPlaylist.playlist[myPlaylist.current].title); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment