Home > Backend Development > PHP Tutorial > Method to implement playback of employee number

Method to implement playback of employee number

巴扎黑
Release: 2016-11-29 10:30:10
Original
1342 people have browsed it

Set setinterfacevar=yes in queue.conf to enable the MEMBERINTERFACE variable;
Then call an agi script in extension.conf when calling queue
(with the parameter, Queue(myqueue|t|||10|agi://192.168.35.3 /hello.agi)
exten => _X., n, Queue(911|tT|||60|Predictive/sayinterface.agi)
In this way, you can use getVariable("MEMBERINTERFACE") in agi to get the connected one queue member name

<?php
include (dirname(__FILE__)."/phpagi_2_14/phpagi.php");
include (dirname(__FILE__)."/phpagi_2_14/phpagi-asmanager.php");
$agi=new AGI();
$temp=$agi->get_variable("MEMBERINTERFACE");
$member=$temp[&#39;data&#39;];
$member=substr($member,4);
$agi->verbose($member);
$agi->say_digits($member);
?>
Copy after login


Related labels:
php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template