"; $query = "SELECT value FROM " . SETTINGSTABLE . " WHERE parameter='CHRISTMAS'"; $sth = $globaldbh->prepare($query); $sth->execute(); $row = $sth->fetch(); $data['christmas'] = ($row['value'] == 'true') ? true : false; $query = "SELECT value FROM " . SETTINGSTABLE . " WHERE parameter='CHRISTMASFREQ'"; $sth = $globaldbh->prepare($query); $sth->execute(); $row = $sth->fetch(); $data['christmasfreq'] = $row['value']; $query = "SELECT songid FROM " . RECENTSTABLE . " ORDER BY timeplayed DESC limit 15"; $sth = $globaldbh->prepare($query); $sth->execute(); $data['volume'] = getSystemVolume(); system("HOME=" . WEBUSERHOMEDIR . " && ../scripts/homeaudio_togglemute.pl -show", $retval); $data['muted'] = ($retval == 0) ? false : true; $data['songplaying'] = ""; $data['songlist'] = ""; $firstsong = true; while ( $row = $sth->fetch() ) { $song = new Song($row['songid']); if ( $firstsong ) { $data['songplaying'] .= "
\n"; $data['songplaying'] .= " \n"; $firstsong = false; } else { $data['songlist'] .= "\n"; $data['songlist'] .= " {$song->getTitle(HTMLSAFE)}
\n"; $data['songlist'] .= " {$song->getArtist(HTMLSAFE)}
\n"; $data['songlist'] .= " {$song->getAlbum(HTMLSAFE)}