Hello,

I am writing AGI scripts using 0.10 of the module on Debian Etch and Lenny.

Asterisk version 1.4.21-dfsg-3 (Debian Sub Build number).

When I read variables with get_variable I get the results, but if I read
several in a row and then display them back the requested information will
be in the wrong variable.  It is off by one in the order I request them.

variable 1 = 10
variable 2 = Agent/1001
Variable 3 = /var/wavefile.wav

my $code = $AGI->get_variable("CODE");
my $recording = $AGI->get_variable("MIXMONITOR_FILENAME");
my $interface = $AGI->get_variable("MEMBERINTERFACE");
if ($DEBUG){
    if (!$code) {
        $AGI->verbose("main: We did not retrieve a Code", 10);
    }
    $AGI->verbose("main: Code is $code", 50);
    $AGI->verbose("main: The Recording is $recording", 50);
    $AGI->verbose("main: The Interface is $interface", 50);
}

This would return:

$code = "NULL"
$recording = 10
$interface = /var/wavefile.wav

Note that getting caller id from %input works just fine all the time.

Thanks,
-- 
Shawn L. Djernes
SD Consulting
[email protected] | [email protected]
MSN: [email protected]
402.345.7734 | 402.350.6973 Cell

Reply via email to