Hi,
I use an AGI with PHP. Here is a short snippet:
[...]
declare(ticks = 1);
pcntl_signal(SIGHUP, array($this, "signal_handler"));
[...]
public function signal_handler($signal_number)
{
$this->log_message("debug", "Signal catched:
signo=$signal_number");
switch($signal_number) {
case SIGHUP:
// signal for hangup (comes from asterisk)
$this->log_message("debug", "Hangup
detected.");
exit(0);
break;
default:
$this->log_message("error", "Undefined signal
'".$signal_number."'.");
break;
}
}
Work for me. Give it a try.
Best regards,
-Thorsten-
Am 21.11.2011 13:00, schrieb David Cunningham:
Thorsten,
We have SIGHUP set to 'IGNORE', but it still does not continue the
AGI after the Dial(). Do you have any idea why that might happen?
Thanks for your advice.
On 21 November 2011 22:19, Thorsten Göllner <t...@ovm-group.com>
wrote:
If the caller hangs up
Asterisk sends a SIGHUP. You can catch the signal and do
whatever you want to do.
Am 21.11.2011 07:38, schrieb David Cunningham:
Hello,
We would like to continue a Perl AGI after a Dial() it
has done completes following caller hangup. We would
like to do this in the same AGI, and not using a new
AGI from the 'h' extension. It works fine when the
called party hangs up and the 'g' option is used, but
not for caller hangup.
Is this possible?
If not a confirmation that this is the case would be
very helpful.
Thanks for any advice!
--
Thorsten Göllner
OVM Office Voice Media GmbH
Herderstrasse 68
40237 Düsseldorf
Tel.: +49(0)211 / 618 57 53
Fax: +49(0)211 / 618 57 54
--
David Cunningham, Voisonics
http://voisonics.com/
US toll-free: +1 888 842 2720
UK: +44 (0) 20 3298 1642
Australia: +61 (0) 2 8063 9019
|
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users