Does anyone know of a way to alert agents that a call is waiting in the queue?![]()


#!/usr/bin/php
<?php
$server = "172.16.0.210";
$queue = "2000";
##### Check to see if this file is already running ###########
$psarray = array();
exec("ps -Af | grep \"CallersInQueue.php\"",$psarray);
if(count($psarray)>3) exit(0);
#############################################################
function push2phone($server,$phone,$data)
{
$xml = "xml=".$data;
$post = "POST / HTTP/1.1\r\n";
$post .= "Host: $phone\r\n";
$post .= "Referer: $server\r\n";
$post .= "Connection: Keep-Alive\r\n";
$post .= "Content-Type: text/xml\r\n";
$post .= "Content-Length: ".strlen($xml)."\r\n\r\n";
$fp = @fsockopen ( $phone, 80, $errno, $errstr, 5);
if($fp)
{
fputs($fp, $post.$xml);
flush();
fclose($fp);
}
}
##############################
$myarray = array();
exec("asterisk -rx\"show queue $queue\" | grep $queue",$myarray);
//$callers = $myarray[0];
$iPos = stripos($myarray[0],'has');
$callers=substr($myarray[0],$iPos+3,20);
$iPos = stripos($callers,'calls');
$callers = (int)trim(substr($callers,0,$iPos));
######## Test
#$callers = 1;
$xml = "<AastraIPPhoneTextScreen Timeout='6' Beep='yes' >\n";
$xml .= "<Title>Inbound Caller Queue</Title>\n";
if($callers > 1)
{ $xml .= "<Text>" . $callers . " Callers in the Queue</Text>\n"; }
else
{ $xml .= "<Text>1 Caller in the Queue</Text>\n";}
$xml .= "</AastraIPPhoneTextScreen>\n";
if($callers > 0) push2phone($server,"172.16.0.201",$xml);
?>
I wonder if there is a visual display (on a PC) of the "Call Queue" in some of these fancier programs like:
Hudlite http://www.hudlite.org
iSymphony - http://www.i9technologies.com/isymphony/
ASTassistant - http://www.astassistant.com/
I will have to research.
...
He sent back this link that might do the trick for you (see the Realtime tab): http://www.asternic.org/stats
The realtime option is only available in the commercial version so you would have to contact Nicolas.
Update from Nicolas:
The realtime view is also available in the free version... you just need to configure the manager settings.
...
TomS
I figured that since there are stats on the standard Flash Operator Panel (FOP) that maybe there was a way to customize the FOP for queue needs.
I sent an email to Nicolas, of the FOP fame, asking if there was a way to tailor the FOP for call center users.
He sent back this link that might do the trick for you (see the Realtime tab): http://www.asternic.org/stats
The realtime option is only available in the commercial version so you would have to contact Nicolas.
Update from Nicolas:
The realtime view is also available in the free version... you just need to configure the manager settings.
His is also working on a CDR stats tool. Hope this does the trick for you!
Thanks Nicolas for all the great work!
TomS
Does anyone know how to configure the manager settings to enable the realtime view?

Link up your team and customers Phone System
Live Chat
Video Conferencing
Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.
Check your inbox!
We’ve sent you an email. Click on the button in the email body to verify your email address – (if you can not find it, check your spam folder).
Upon verification you will be directed to the 3CX setup wizard.