[Asterisk-Dev] More than one param to AGI

Eric Wieling eric at fnords.org
Fri Jun 20 22:23:00 MST 2003


I'm starting to write an AGI script.  I want to pass more than one
parameter to the script, but seem to be unable to.

extensions.conf:
   exten => 85,1,AGI(/etc/asterisk/agi/args.agi,myarg1,myarg2)

args.agi:
   #!/usr/bin/perl
   print STDERR "FNORD prog = $0\n";
   print STDERR "FNORD arg 1 = $ARGV[0]\n";
   print STDERR "FNORD arg 2 = $ARGV[1]\n";
   print STDERR "FNORD arg 3 = $ARGV[2]\n";
   print STDERR "FNORD arg 4 = $ARGV[3]\n";

What I get at the console:
   FNORD prog = /etc/asterisk/agi/args.agi
   FNORD arg 1 = myarg1
   FNORD arg 2 =
   FNORD arg 3 =
   FNORD arg 4 =

Is this just a limitation of AGI or am I horribly confuzzled?

--Eric

-- 
BTEL Consulting
850-484-4535 x2111 (Office)
504-595-3916 x2111 (Experimental)
877-552-0838 (Backup Phone)




More information about the asterisk-dev mailing list