@ 2013-12-15T03:51:52Z <?PHP
// Shoutcast Server Stats
// Parses shoutcasts xml to make an effective stats thing for any website
// ©2004-2005 Daniel Brown http://www.gmtt.co.uk
// Please refer to the readme file for use.
include('config_radio.php'); //you may edit this path to fit your server environment otherwise leave it alone
$scfp = fsockopen("$scip", $scport, &$errno, &$errstr, 30);
if(!$scfp) {
$scsuccs=1;
$locutor = 'Sin Locutor';
$actuals = 'Sin Cancion Actual';
$canciones = '
<b>1.</b> Sin Canciones Pasadas <BR><BR>
<b>2.</b> Sin Canciones Pasadas <BR><BR>
<b>3.</b> Sin Canciones Pasadas <BR><BR>
<b>4.</b> Sin Canciones Pasadas <BR><BR>
<b>5.</b> Sin Canciones Pasadas <BR><BR>'
;
}
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"){
//you may edit the html below, make sure to keep variable intact
$locutor = ''.$servertitle.'';
$actuals = ''.$song[0].'';
$canciones = '
<b>1.</b> '.$song[1].'<BR><BR>
<b>2.</b> '.$song[2].'<BR><BR>
<b>3.</b> '.$song[3].'<BR><BR>
<b>4.</b> '.$song[4].'<BR><BR>
<b>5.</b> '.$song[5].'<BR><BR>'
;
}
if($streamstatus == "0")
{
//you may edit the html below, make sure to keep variable intact
$locutor = 'Sin Locutor';
$actuals = 'Sin Cancion Actual';
$canciones = '
<b>1.</b> Sin Canciones Pasadas <BR><BR>
<b>2.</b> Sin Canciones Pasadas <BR><BR>
<b>3.</b> Sin Canciones Pasadas <BR><BR>
<b>4.</b> Sin Canciones Pasadas <BR><BR>
<b>5.</b> Sin Canciones Pasadas <BR><BR>'
;
}
?>
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).
Version System time (s) User time (s) Memory (MiB) 5.4.23 0.024 0.100 12.32 5.4.22 0.020 0.041 12.33 5.4.21 0.016 0.046 12.33 5.4.20 0.027 0.040 12.32 5.4.19 0.019 0.045 12.32 5.4.18 0.049 0.111 12.32 5.4.17 0.015 0.047 12.33 5.4.16 0.026 0.040 12.32 5.4.15 0.023 0.072 12.32 5.4.14 0.016 0.048 12.01 5.4.13 0.016 0.046 11.99 5.4.12 0.029 0.092 11.96 5.4.11 0.021 0.046 11.95 5.4.10 0.012 0.049 11.95 5.4.9 0.017 0.044 11.95 5.4.8 0.021 0.047 11.95 5.4.7 0.022 0.039 11.95 5.4.6 0.014 0.052 11.94 5.4.5 0.015 0.045 11.94 5.4.4 0.014 0.045 11.93 5.4.3 0.022 0.041 11.93 5.4.2 0.031 0.092 11.93 5.4.1 0.014 0.049 11.93 5.4.0 0.020 0.046 11.42 5.3.29 0.008 0.042 12.80 5.3.28 0.024 0.074 12.70 5.3.27 0.019 0.048 12.72 5.3.26 0.018 0.060 12.72 5.3.25 0.058 0.102 12.72 5.3.24 0.020 0.045 12.72 5.3.23 0.036 0.107 12.71 5.3.22 0.021 0.042 12.68 5.3.21 0.026 0.054 12.68 5.3.20 0.032 0.096 12.68 5.3.19 0.022 0.074 12.68 5.3.18 0.019 0.054 12.67 5.3.17 0.021 0.046 12.67 5.3.16 0.013 0.050 12.67 5.3.15 0.047 0.080 12.68 5.3.14 0.022 0.044 12.66 5.3.13 0.012 0.050 12.66 5.3.12 0.025 0.037 12.66 5.3.11 0.017 0.047 12.66 5.3.10 0.016 0.048 12.12 5.3.9 0.014 0.047 12.08 5.3.8 0.018 0.048 12.07 5.3.7 0.024 0.067 12.07 5.3.6 0.019 0.043 12.07 5.3.5 0.020 0.042 12.00 5.3.4 0.018 0.044 12.00 5.3.3 0.016 0.046 11.97 5.3.2 0.023 0.041 11.75 5.3.1 0.020 0.041 11.71 5.3.0 0.019 0.044 11.70
preferences:dark mode live preview
137.71 ms | 1394 KiB | 7 Q