5 $cur_track = $mpd->current_track_id;
6 $playlist = $mpd->playlist;
8 $playlist_count = $mpd->playlist_count;
12 $trackno=$cur_track+1;
14 echo "<div class=\"trackno\">#$trackno/$playlist_count</div>";
15 if ($playlist[$cur_track]['name']==$playlist[$cur_track]['title']) {
16 echo "<div class=\"trackname\">".htmlentities(cut_file($playlist[$cur_track]['name']))."</div>";
18 echo "<div class=\"trackname\">".htmlentities($playlist[$cur_track]['title'])."</div>";
22 echo "<div class=\"trackno\">#-/$playlist_count</div>";
23 echo "<div class=\"trackname\">No track selected</div>";