require('stats/stathit.php'); stathit($_SERVER['PHP_SELF']); ?>
Unfortunatly gjukebox development died a couple of years ago, its in a very good state though just not compatible with the latest versions of perl, php, mysql, etc.
Fortunatly I have worked through the bugs and provide mods here.
The following is a list of files and lines that need changing:
$ sudo gedit /usr/local/jukebox/jukebox/action.php
Change line 307 to: mysql_query("insert into users values ($user,old_password($pwd),1)");
Change line 310 to: mysql_query("delete from users where name = 'anonymous' and pass = old_password('')");
Change line 786 to: $pass=", pass = old_password(".prepareDB(${"PASS".$user}).")";
Change line 794 to: mysql_query("insert into users values ('$NAME',old_password($pass),$QUEUE)");
After this is done it will be necessary to update the mysql passwords manually, I use phpmyadmin for this kind of stuff, its a case of looking through the jukebox users and adding one with an old_password as the password encryption.
$ sudo gedit /usr/local/jukebox/jukebox/connect.php
change line 52 to: $result=mysql_query("SELECT pass , queue FROM users WHERE name = $authuser and pass = old_password($authpwd)");
$sudo gedit /jukebox/www/program.php
Change line 839 to: $select.=") or a.artist is null)";
$sudo gedit /usr/local/jukebox/jukebox/getnextmp3.pl
change line 103 to my $userating=fetchsetting("RATINGS");
These are all the changes I have made to get the jukebox interface and deamons to work correctly on the latest MySQL, PHP, Apache etc.
I have done more mods but these were mainly personal mods to allow a good working environment in the pub and in no way make it work correctly.
There are a couple of database entries that need changing also before it will run correctly:
You need to navigate to the settings database in phpmyadmin and change the names of these keys:
COVERVARIUS needs its name changed to COVERVARIOUS (silly typo)
RATING needs its name changed to RATINGS
You need to enable randomly chosen tracks to be shown on the menu or you'll get mysql errors, I suppose I could have fixed this aswell but I didnt really need to as enabling this feature does it anyway!
The album art script doesnt work with amazon in its default state, I re-wrote the script and it can be found HERE