[ascoders] shoutcast stream
- From: volker Kreß <kress@xxxxxxxxxx>
- To: ascoders@xxxxxxxxxxxxx
- Date: Tue, 30 Mar 2004 13:35:22 +0200
Hallo Liste,
hat jemand einen Link zu Shoutcaststreams in Flash?
ich Versuch es hiermit aber es läuft leider nicht
Flash -->
mysound = new Sound()
mysound.load("myphp.php", true);
mysound.onLoad = function()
{
this.start();
trace(this)
trace(this.getBytesTotal())
}
PHP -->
<?
$streamname = "http://64.236.34.196";; // put in whatever stream
you want to play
$port = "80"; // put in the port of the stream
$path = "/stream/1040"; // put in any extra path, this is
usually just a /
header("Content-type: audio/mpeg");
$sock = fsockopen($streamname,$port);
fputs($sock, "GET $path HTTP/1.0\r\n");
fputs($sock, "Host: $streamname\r\n");
fputs($sock, "User-Agent: itunes\r\n");
fputs($sock, "Accept: */*\r\n");
fputs($sock, "Icy-MetaData:1\r\n");
fputs($sock, "Connection: close\r\n\r\n");
fpassthru($sock);
fclose($sock);
?>
Grüße
------------------------------------------------------
Archiv : //www.freelists.org/archives/ascoders/
Optionen : //www.freelists.org/list/ascoders
------------------------------------------------------
Other related posts: