Soporte & Consultoria

Soporte Remoto y Consultoria skype : ambiorixg12.
Nota no se brinda ningun tipo de consulta o soporte fuera del blog de forma gratuita

lunes, 15 de agosto de 2016

asterik spy avatar

exten => s,1,Answer
same=>n,ChanSpy(${chan},Bq)   ; channel passed from the url


/*parameters */

$param= array("host"=>"localhost","port"=>5038,"trunk"=>"tw0","timeout"=>45);

/*form variables */


$socket = fsockopen($param['host'],$param['port'], $errno, $errstr,$param['timeout']);
 fputs($socket, "Action: Login\r\n");
 fputs($socket, "UserName: admin\r\n");
 fputs($socket, "Secret:1456\r\n\r\n");
              echo $wrets;
              fputs($socket, "Action: Originate\r\n" );
              fputs($socket, "Channel: Local/s@spy\r\n" );
              fputs($socket, "Application: playback\r\n" );
              fputs($socket, "Data: $msg\r\n" );
              fputs($socket, "CallerID: $cid\r\n" );
              fputs($socket, "Variable: __var1=$src\r\n" );
              fputs($socket, "Variable: __chan=$chan\r\n" );
              fputs($socket, "Async: yes\r\n\r\n" );
              fputs($socket, "Action: Logoff\r\n\r\n");

 sleep (1);
/* test url

$_GET['chan'];=channel where  audio will be played, as using B, audio will be played   to  both channels

If you want to play the audio file to   an specific channel only use the W  option

No hay comentarios:

Publicar un comentario