Pessoal, bom dia!!<br><br>Estou com o seguinte problema:<br><br>Criei um script em PHP apenas para gerar uma chamada simples utilizando manager.conf e Originate e esta dando erro, estou passando as configurações.<br><br>arquivo php:<br>
<br><p><?php</p>
<p>$socket = fsockopen(“127.0.0.1″,”5038″,$errno,$errstr,$timeout);<br>
fputs($socket,”Action: Login\r\n”);<br>
fputs($socket,”UserName: usuário no manager\r\n”);<br>
fputs($socket,”Secret: senha no manager\r\n\r\n”);<br>
fputs($socket,”Action: Originate\r\n”);<br>
fputs($socket,”Channel: SIP/1/99999999\r\n”);<br>
fputs($socket,”Context: monitor\r\n”);<br>
fputs($socket,”Exten: ramal\r\n”);<br>
fputs($socket,”Callerid: numero do ramal\r\n”);<br>
fputs($socket,”Priority: 1\r\n\r\n”);</p>
<p>?></p><br>manager.conf<br><br>[general]<br>enabled = yes<br>webenabled = no<br><br>port = 5038<br>bindaddr = 0.0.0.0<br><br>[usuário do manager]<br>secret=senha manager<br>read = system,call,log,verbose,command,agent,user,originate<br>
write = system,call,log,verbose,command,agent,user,originate<br><br><br>Erro:<br><br><br> == Manager 'admin' logged on from 127.0.0.1<br>[Aug 29 09:24:36] ERROR[2711]: utils.c:1211 ast_careful_fwrite: fwrite() returned error: Broken pipe<br>
[Aug 29 09:24:36] ERROR[2711]: utils.c:1211 ast_careful_fwrite: fwrite() returned error: Broken pipe<br>[Aug 29 09:24:36] ERROR[2711]: utils.c:1211 ast_careful_fwrite: fwrite() returned error: Broken pipe<br> == Manager 'admin' logged off from 127.0.0.1<br>
<br><br>