Posted on: 10/05/04 09:58am
By: Kutulu
Posted on: 10/07/04 03:57pm
By: Kutulu
Posted on: 11/01/04 09:57am
By: varian vega
Posted on: 11/01/04 12:15pm
By: Anonymous (Kutulu)
Posted on: 11/20/04 09:35pm
By: Faust-Eternal
Posted on: 11/20/04 10:02pm
By: squatty
Posted on: 09/11/05 06:36pm
By: Anonymous (reggierich)
Posted on: 09/12/05 05:33am
By: Anonymous (Trinity)
Function phpblock_radio () { // Fill in your own server information here: $host = "darkpitradio.elitepalaces.com"; $port = "8000"; $listenlink = 'http://darkpitradio.elitepalaces.com:8000/listen.pls'; //make link to stream $fp = fsockopen("$host", $port, &$errno, &$errstr, 30); //open connection if(!$fp) { $success=2; //se-t if no connection } if($success!=2){ //if connection fputs($fp,"GET /7.html HTTP/1.0rnUser-Agent: XML Getter (Mozilla Compatible)rnrn"); //get 7.html while(!feof($fp)) { $page .= fgets($fp, 1000); } fclose($fp); //close connection $page = ereg_replace(".*<body>", "", $page); //extract data $page = ereg_replace("</body>.*", ",", $page); //extract data $numbers = explode(",",$page); //extract data $currentlisteners=$numbers[0]; //set variable $connected=$numbers[1]; //set variable if($connected==1) //if DSP is connected $wordconnected="yes"; //set variable else //if no DSP connection $wordconnected="no"; //set variable $peaklisteners=$numbers[2]; //set variable $maxlisteners=$numbers[3]; //set variable $reportedlisteners=$numbers[4]; //set variable } if($success!=2 && $connected==1){ // song information is splitted in artist - title: // This requires consistent artist & title format (no ' - ' in title/artist) // else you can use $numbers[6] as current song info below $song=explode(" - ",$numbers[6]); // strings can of course be replaced with your own bla $display .= "Now playing on Darkpit Radio<br>"; $display .= "Artist: ". $song[0] . "<br>"; $display .= "Song: ". $song[1] . "<br>"; $display .= "[$currentlisteners/$maxlisteners users]"."<br> <a target='_new' href=' " . $listenlink ."'>[click to listen]</a> "; } else { $display .= "Darkpit Radio is currently"; $display .= "OFFLINE."; $display .= "Please return later."; $display .=":::"; } return $display; }
Posted on: 04/10/06 09:53am
By: Anonymous (Lasse)