Hi,

I'm trying to understand how AGI works.
I'm using php-agi library from sf.net.

*CLI> agi show commands
  Yes                           exec   Executes a given Application

*CLI> core show application set

My PHP-AGI script contains:

$AGI->exec("Set", "CUSTOM_VAR=2");
$AGI->exec("NoOp", "\"DEBUG - ${CUSTOM_VAR}\"");

An AGI debug from *CLI shows:

<SIP/4053-0000004d>AGI Rx << EXEC Set CUSTOM_VAR=2
    -- AGI Script Executing Application: (Set) Options: (CUSTOM_VAR=2)
<SIP/4053-0000004d>AGI Tx >> 200 result=0
<SIP/4053-0000004d>AGI Rx << EXEC NoOp "DEBUG - "
    -- AGI Script Executing Application: (NoOp) Options: (DEBUG - )

Why isn't CUSTOM_VAR set?

I know I could use agi command "set variable" but I'd like to know why the 
above code doesn't seem to work.

Also, there's no AGI-specific command for NoCDR(). So I did something like this:

$AGI->exec("NoCDR", "");

but the CDR was written to cdr-csv/Master.csv so I'm assuming I'm doing 
something wrong with the "agi exec command".

Any ideas?

Thanks,

Vieri


--
_____________________________________________________________________
-- 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

Reply via email to