Segue o modelo que eu utilizo: 1 - Configuracao do manager.conf ; /etc/asterisk/manager.conf 2 - Configuracao do extensions.conf ;/etc/asterisk/extensions.conf 3 - Conexao AMI PHP ; /var/www/dial/dial.php 4 - Form HTML, envia os numeros desejados de A e B.
*manager.conf* [general] enabled = yes webenabled = yes port = 5038 debug = yes ;httptimeout = 60 ; a) httptimeout sets the Max-Age of the http cookie ; b) httptimeout is the amount of time the webserver waits ; on a action=waitevent request (actually its httptimeout-10) ; c) httptimeout is also the amount of time the webserver keeps ; a http session alive after completing a successful action bindaddr = 127.0.0.1 ;displayconnects = yes ; ; Add a Unix epoch timestamp to events (not action responses) ; ;timestampevents = yes [seuusuario] secret = senhausuario permite=0.0.0.0/0.0.0.0 permit=127.0.0.1/255.255.255.0 read = system,call,log,verbose,agent,user,config,dtmf,reporting,cdr,dialplan write = system,call,agent,log,verbose,user,config,command,reporting,originate,donglesendsms ;writetimeout = 100 ;read = system,call,log,verbose,command,agent,user,config,originate,command,all,DongleSendSMS ;write = system,call,log,verbose,command,agent,user,config,originate,command,all,DongleSendSMS ;read = call,all ;write = call,all *extensions.conf* [local] include => default *dial.php* <?php $src=$_GET["src"]; $dst=$_GET["dst"]; #$src="8188888888"; #$dst="6888888888"; $socket = @fsockopen("127.0.0.1","5038", $errno, $errstr, $timeout); $cmd[]=" Action: Login UserName: seuusuario Secret: senhausuario Action: Originate Channel: Local/$src@local Context: local Priority: 1 Exten: $dst Callerid: $src Async: yes Action: Logoff "; $lines=$cmd; foreach ($lines as $line_num => $line) { fwrite($socket, "$line\r\n"); //echo $line; //echo fread($socket, 128); } sleep(5); fclose($socket); echo "Ligou"; header('Location:index.html'); ?> *index.html* <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Click to Dial</title> </head> <center> <img src="click.gif" alt="some_text"/> </center> <h2><p align=center> Click To Dial</center></h2> <p align=center> <h3><p align=center> Exemplo de discagem:(DD) + Telefone.</center></h3> <h4><p align=center> 1 Digite o numero do seu telefone: </center></h4> <h4><p align=center> 2 Digite o numero que deseja falar: </center></h4> <h4><p align=center> 3 Click em Ligar. </center></h4> <body> <form name="formulario" action="ciao.php?src&dst" method="get"> <p align=center><label>1:</label><img src="icon.png" alt="Seu Telefone:"/> <input type="text" name="src" id="txtNome" /> <br /> <label>2: </label><img src="icon.png" alt="Telefone Desejado:"/> <input type="text" name="dst" id="txtTelefone" /> <br /> <input type="submit" name="cmdEnviar" id="cmdEnviar" value=" Ligar " /><center> </form> </body> </center> </html> Em 5 de novembro de 2013 13:55, Kendon Rojas <kendon.ro...@gmail.com>escreveu: > Isso tem que ser feito automatizado ou pode ter intervenção de um > atendente? > > > 2013/11/5 Sylvio Jollenbeck <sylvio.jollenb...@gmail.com> > >> Everton, >> >> A app Originate faz exatamente isso.... Disca para A, se A atender >> disca para B. >> >> Abs, >> >> >> Em 5 de novembro de 2013 16:06, Everton Carneiro < >> ever...@visaotecnologia.com> escreveu: >> >>> Pessoal tenho a seguinte situação, faço Dial para ponto A e apos o >>> mesmo atender preciso fazer outro Dial para ponto B isso é posivel? ou >>> posso colocar ponto A em espera de depois fazer o Dial para o ponto B? >>> >>> -- >>> *Everton Carneiro .:* >>> >>> *Visão Tecnologia* >>> >>> *Fortaleza-CE 85-3044 8888 / 3044-8844* >>> >>> *Cel: Tim 85-9665 0888 <85-9665%200888> * >>> >>> Preserve o verde, antes de imprimir veja se realmente é necessário. >>> >>> _______________________________________________ >>> KHOMP: completa linha de placas externas FXO, FXS, GSM e E1; >>> Media Gateways de 1 a 64 E1s para SIP com R2, ISDN e SS7; >>> Intercomunicadores para acesso remoto via rede IP. Conheça em >>> www.Khomp.com. >>> _______________________________________________ >>> ALIGERA – Fabricante nacional de Gateways SIP-E1 para R2, ISDN e SS7. >>> Placas de 1E1, 2E1, 4E1 e 8E1 para PCI ou PCI Express. >>> Channel Bank – Appliance Asterisk - Acesse www.aligera.com.br. >>> _______________________________________________ >>> Para remover seu email desta lista, basta enviar um email em branco para >>> asteriskbrasil-unsubscr...@listas.asteriskbrasil.org >>> >> >> >> >> -- >> Sylvio Jollenbeck >> www.hosannatecnologia.com.br >> >> >> _______________________________________________ >> KHOMP: completa linha de placas externas FXO, FXS, GSM e E1; >> Media Gateways de 1 a 64 E1s para SIP com R2, ISDN e SS7; >> Intercomunicadores para acesso remoto via rede IP. Conheça em >> www.Khomp.com. >> _______________________________________________ >> ALIGERA – Fabricante nacional de Gateways SIP-E1 para R2, ISDN e SS7. >> Placas de 1E1, 2E1, 4E1 e 8E1 para PCI ou PCI Express. >> Channel Bank – Appliance Asterisk - Acesse www.aligera.com.br. >> _______________________________________________ >> Para remover seu email desta lista, basta enviar um email em branco para >> asteriskbrasil-unsubscr...@listas.asteriskbrasil.org >> > > > _______________________________________________ > KHOMP: completa linha de placas externas FXO, FXS, GSM e E1; > Media Gateways de 1 a 64 E1s para SIP com R2, ISDN e SS7; > Intercomunicadores para acesso remoto via rede IP. Conheça em > www.Khomp.com. > _______________________________________________ > ALIGERA – Fabricante nacional de Gateways SIP-E1 para R2, ISDN e SS7. > Placas de 1E1, 2E1, 4E1 e 8E1 para PCI ou PCI Express. > Channel Bank – Appliance Asterisk - Acesse www.aligera.com.br. > _______________________________________________ > Para remover seu email desta lista, basta enviar um email em branco para > asteriskbrasil-unsubscr...@listas.asteriskbrasil.org >
_______________________________________________ KHOMP: completa linha de placas externas FXO, FXS, GSM e E1; Media Gateways de 1 a 64 E1s para SIP com R2, ISDN e SS7; Intercomunicadores para acesso remoto via rede IP. Conheça em www.Khomp.com. _______________________________________________ ALIGERA Fabricante nacional de Gateways SIP-E1 para R2, ISDN e SS7. Placas de 1E1, 2E1, 4E1 e 8E1 para PCI ou PCI Express. Channel Bank Appliance Asterisk - Acesse www.aligera.com.br. _______________________________________________ Para remover seu email desta lista, basta enviar um email em branco para asteriskbrasil-unsubscr...@listas.asteriskbrasil.org