我对星号是新的,它已经安装好了,我有了所有的主机细节,我需要的是如何在我的symfony2 web应用程序中使用星号;有人有一个想法,或者他以前做过这样的工作?
编辑
以下是我在我的web应用程序中应该做的事情:
编辑1
我从控制器中的小代码开始:
use Pastum\Component\PAMI\Client\Client;
/* These are (in order) the options we can pass to PAMI client:
*
* The hostname or ip address where Asterisk AMI is listening
* The scheme can be tcp:// or tls://
* The port where Asterisk AMI is listening
* Username configured in manager.conf
* Password configured for the above user
* Connection timeout in milliseconds
* Read timeout in milliseconds
*/
$options = array(
'host' => '127.0.0.1',
'scheme' => 'tcp://',
'port' => 9999,
'username' => 'admin',
'secret' => 'mysecret',
'connect_timeout' => 10000,
'read_timeout' => 10000
);
$client = new Client($options);
// Open the connection
$client->open();
// Close the connection
$client->close();但是我不知道在视图页面或连接之后我能做些什么?
以及如何使用代码执行需要的命令?!
发布于 2015-05-03 11:37:33
https://stackoverflow.com/questions/30012840
复制相似问题