No to tak w pliku shoucast.class mam taki kod:
[php]<?php
class ShoutCAST {
var $host, $port, $pass, $dane, $values, $indexes;
function connect() {
$fp = fsockopen($this->host, $this->port, $errno, $errstr, 10);
if (!$fp) { return false;
} else {
fputs($fp, "GET /admin.cgi?pass=".$this->pass."&mode=viewxml HTTP/1.0\r\n");
fputs($fp, "User-Agent: Mozilla\r\n\r\n");
while (!feof($fp)) {
$this->dane .= fgets($fp, 512);
}
fclose($fp);
if (stristr($this->dane, "HTTP/1.0 200 OK") != true) return false;
$code_xml = xml_parser_create();
if (!xml_parse_into_struct($code_xml, $this->dane, $this->values, $this->indexes)) return false;
xml_parser_free($code_xml);
return true;
}
}
function showValue($which) {
return($this->values[$this->indexes[$which][0]]["value"]);
}
}
?>[/php]
a w pliki shoutcast.php taki:
[php]<?php
include(‘shoutcast.class’);
$shoutcast = new ShoutCAST();
$shoutcast->host = "192.189.45.3"; // adres IP serwera
$shoutcast->port = 8000; // port serwera
$shoutcast->passwd = "haslo"; // hasło do serwera
if ($shoutcast->connect()) {
if ($shoutcast->showValue(‘STREAMSTATUS’)) {
print “Nazwa serwera:”.$shoutcast->showValue(‘SERVERTITLE’)).”<br>”;
print “Ilość słuchaczy:”.$shoutcast->showValue(‘CURRENTLISTENERS’)).”<br>”;
print “Limit słuchaczy:”.$shoutcast->showValue(‘MAXLISTENERS’)).”<br>”;
print “Rekord słuchaczy:”.$shoutcast->showValue(‘PEAKLISTENERS’)).”<br>”;
print “Rodzaj serwera:”.$shoutcast->showValue(‘SERVERGENRE’)).”<br>”;
print “URL serwera:”.$shoutcast->showValue(‘SERVERURL’)).”<br>”;
print “Nazwa piosenki:”.$shoutcast->showValue(‘SONGTITLE’)).”<br>”;
print “Jakość nadawania:”.$shoutcast->showValue(‘BITRATE’)).”<br>”;
print “IRC:”.$shoutcast->showValue(‘IRC’)).”<br>”;
print “AIM:”.$shoutcast->showValue(‘AIM’)).”<br>”;
print “ICQ:”.$shoutcast->showValue(‘ICQ’)).”<br>”;
} else {
print "Serwer jest włączony, ale aktualnie nie ma żadnej audycji.";
}
} else {
print “Serwer jest wyłączony.”;
}
?> [/php]
oczywiscie dane serwera są przykładowe w pliku mam prawidłowe

sorka że tak długo nie odpisywałem ale nie miałem neta przez ten okres