Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Variable */
- var $RadioInfo = 'semnome';
- /* Handle */
- case 'i':
- $info = explode(';=', $this->packet['i']['b']);
- $this->RadioInfo = str_replace("http://", "", $info[4]);
- break;
- /* Command */
- case 'radio':
- $conexao = explode( ':', $this->RadioInfo );
- $url = fsockopen($conexao[0],$conexao[1]);
- if($this->RadioInfo == 'semnome' or !$this->RadioInfo){$this->sendMessage("Este chat grupo não tem uma radio."); return false;}
- if(!$url){$this->sendMessage("Falha de conexão."); return false;} else {
- fputs($url,"GET /7.html HTTP/1.1\nUser-Agent:Mozilla\n\n");
- $socket = fread($url, 1000);
- $retornar = explode(",", $socket);
- $final = str_replace("</body></html>", "", $retornar[6]);
- if(!$final){$this->sendMessage("Musica atual: Sem nome."); return false;} else
- $this->sendMessage("Musica atual: {$final}");
- }
- break;
- /*
- #Need radio on your xat group current.
- */
Advertisement
Add Comment
Please, Sign In to add comment