PODPANEL ERROR?

Zephyrus

Wanderer
Sep 28, 2011
336
21
So basically, I keep getting this error...


Fatal error
: Call-time pass-by-reference has been removed in /home/paraworl/public_html/spacehabbo.co.uk/radio/radio_stats.php on line 3


The configuration page is:

<?php
include("config.php");
$connect = mysql_query("SELECT * FROM info");
$config = mysql_fetch_array($connect);
//////////////////////////////////////////////////////////////////////////////////////////////
// Stats Information
// Grabs the xml from your radio server and displays it in a iframe that refreshes every 30 seconds.
//////////////////////////////////////////////////////////////////////////////////////////////
//Configuration
$scdef = "SpaceHabbo"; // Default station name to display when server or stream is down
$scip = $config['free.freeshoutcast.com']; // ip or url of shoutcast server
$scport = $config['#####']; // port of shoutcast server
$scpass = $config['#####']; // password to shoutcast server
//End configuration

?>

I cant fix it.......



THE RADIO_STATS PAGE IS { THIS IS THE PAGE I WANT TO WORK!!}


<?php
include('/radio/config_radio.php'); //you may edit this path to fit your server environment otherwise leave it alone
$scfp = fsockopen("$scip", $scport, &$errno, &$errstr, 10);
if(!$scfp) {
$scsuccs=1;
echo''.$scdef.' VirtualHabbo Is Currently Offline';
}
if($scsuccs!=1){
fputs($scfp,"GET /admin.cgi?pass=$scpass&mode=viewxml HTTP/1.0\r\nUser-Agent: SHOUTcast Song Status (Mozilla Compatible)\r\n\r\n");
while(!feof($scfp)) {
$page .= fgets($scfp, 1000);
}
######################################################################################################################
/////////////////////////part 1 \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
//define xml elements
$loop = array("STREAMSTATUS", "BITRATE", "SERVERTITLE", "CURRENTLISTENERS");
$y=0;
while($loop[$y]!=''){
$pageed = ereg_replace(".*<$loop[$y]>", "", $page);
$scphp = strtolower($loop[$y]);
$$scphp = ereg_replace("</$loop[$y]>.*", "", $pageed);
if($loop[$y]==SERVERGENRE || $loop[$y]==SERVERTITLE || $loop[$y]==SONGTITLE || $loop[$y]==SERVERTITLE)
$$scphp = urldecode($$scphp);

// uncomment the next line to see all variables
//echo'$'.$scphp.' = '.$$scphp.'<br>';
$y++;
}
//end intro xml elements
######################################################################################################################
######################################################################################################################
/////////////////////////part 2\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
//get song info and history
$pageed = ereg_replace(".*<SONGHISTORY>", "", $page);
$pageed = ereg_replace("<SONGHISTORY>.*", "", $pageed);
$songatime = explode("<SONG>", $pageed);
$r=1;
while($songatime[$r]!=""){
$t=$r-1;
$playedat[$t] = ereg_replace(".*<PLAYEDAT>", "", $songatime[$r]);
$playedat[$t] = ereg_replace("</PLAYEDAT>.*", "", $playedat[$t]);
$song[$t] = ereg_replace(".*<TITLE>", "", $songatime[$r]);
$song[$t] = ereg_replace("</TITLE>.*", "", $song[$t]);
$song[$t] = urldecode($song[$t]);
$dj[$t] = ereg_replace(".*<SERVERTITLE>", "", $page);
$dj[$t] = ereg_replace("</SERVERTITLE>.*", "", $pageed);
$r++;
}
//end song info

fclose($scfp);
}

//display stats
if($streamstatus == "1"){


/* Blingers fix to get the current DJ */

$abc = array("a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x");

// get the day
$day = strtolower(date("l"));
// get the current time into an int
$timeNow = date("H", time()) -1;

if($timeNow < 0){
$timeNow = 0;
}
// select the letter from the alphabet from the int above
$timeQuery = $abc[$timeNow];

// select the DJ from the DB
$getOnlineDJ = mysql_query("SELECT $timeQuery FROM `$day`");
$rows = mysql_fetch_array($getOnlineDJ);

// current DJ
$currentDJ = $rows[$timeQuery];

/* End Blingers DJ fix */

// Get the habbo name from the DJ name
$habbo = mysql_query("SELECT * FROM users WHERE djname='{$currentDJ}'");
$row = mysql_fetch_array($habbo);
$habboname = $row['habboname'];
if(is_null($habboname)){
$habboname = "SirTezza";
}
//you may edit the html below, make sure to keep variable intact
echo'
<head>
<META HTTP-EQUIV="REFRESH" CONTENT="10;URL=radio_stats.php">

</head>

<img src=" " align="right">
<b>Current DJ:</b><br>'.$servertitle.'<br>
<b>Listeners:</b><br>&nbsp;'.$currentlisteners.'<br>
<b>Current Song:</b><br><marquee> '.$song[0].'</marquee><br>

<b><u>Recently Played Songs:</b></u><br>
<b>1.</b> '.$song[1].'<br>
<b>2.</b> '.$song[2].'<br>
<b>3.</b> '.$song[3].'<br>
<b>4.</b> '.$song[4].'<br>
';
}
if($streamstatus == "0")
{
//you may edit the html below, make sure to keep variable intact
echo'
<html>
<META HTTP-EQUIV="REFRESH" CONTENT="10;URL=radio_stats.php">
</head>

<div class="offline"><b>VirtualHabbo Radio appears to be offline.</b><br>
Please check back later.</div>
</body>

</html>';
}
?></font>
</body>
 

Users who are viewing this thread

Top