[Asterisk-Users] Asterisk Perl AGI
Simone Ricci
simone.ricci at cwnet.it
Wed Oct 6 00:39:34 MST 2004
Victor Cartes wrote:
[cut]
>
> exten => 771,1,AGI,myagi.agi
>
>
> Then, this is my code...
>
> #!/usr/bin/perl
>
> use Asterisk::AGI;
> $AGI = new Asterisk::AGI;
> my %input = $AGI->ReadParse();
>
> $AGI->answer();
>
> my $pin = $AGI->get_data("beep");
>
> exit(0);
>
> Can somebody tell me why the number I enter after the "beep" is not then
> stored in $pin ?
I have this block in one of my agi's, and it works for me:
my $retval = $agi->get_data('ivr-benvenuti', 10000, 1);
$agi->hangup unless ($retval eq 1);
Hope this helps.
Cheers,
Simone.
More information about the asterisk-users
mailing list