Use better album art parameter name for JSON object response

This commit is contained in:
Junior 2024-06-01 13:53:04 -04:00
parent b339af3103
commit d793790fe5
2 changed files with 2 additions and 2 deletions

View File

@ -35,7 +35,7 @@ $firstsong = true;
while ( $row = $sth->fetch() ) { while ( $row = $sth->fetch() ) {
$song = new Song($row['songid']); $song = new Song($row['songid']);
if ( $firstsong ) { if ( $firstsong ) {
$data['currentsong']["art"] = $song->getArtFile(ARTURL); $data['currentsong']["arturl"] = $song->getArtFile(ARTURL);
$data['currentsong']["title"] = $song->getTitle(HTMLSAFE); $data['currentsong']["title"] = $song->getTitle(HTMLSAFE);
$data['currentsong']["artist"] = $song->getArtist(HTMLSAFE); $data['currentsong']["artist"] = $song->getArtist(HTMLSAFE);
$data['currentsong']["album"] = $song->getAlbum(HTMLSAFE); $data['currentsong']["album"] = $song->getAlbum(HTMLSAFE);

View File

@ -191,7 +191,7 @@ function getSongList() {
$('#volume_slider').slider("value", data.volume); $('#volume_slider').slider("value", data.volume);
} }
$('#history_contents').html(data.songlist); $('#history_contents').html(data.songlist);
$('#playing_img').attr("src", data.currentsong.art); $('#playing_img').attr("src", data.currentsong.arturl);
$('#playing_title').html(data.currentsong.title); $('#playing_title').html(data.currentsong.title);
$('#playing_artist').html(data.currentsong.artist); $('#playing_artist').html(data.currentsong.artist);
$('#playing_album').html(data.currentsong.album); $('#playing_album').html(data.currentsong.album);