[Home]

Summary:ASTERISK-04623: ${PRIORITY} is not accessible with AGI
Reporter:Johann Hoehn (johann)Labels:
Date Opened:2005-07-19 14:59:14Date Closed:2011-06-07 14:10:15
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Resources/res_agi
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) priority.php
Description:I'm using the PHPAGI library when making AGI scripts.  I noticed that the variable ${PRIORITY} is not accessible with the "GET VARIABLE" AGI command.

****** ADDITIONAL INFORMATION ******

extensions.conf
---------------
[priority-test]
exten => s,1,NoOp(Priority is ${PRIORITY})
exten => s,2,AGI(priority.php)
exten => s,3,NoOp(Priority is ${PRIORITY})

output is
----------
   -- Executing NoOp("SIP/7000-fec2", "Priority is 1") in new stack
   -- Executing AGI("SIP/7000-fec2", "priority.php") in new stack
   -- Launched AGI Script /var/lib/asterisk/agi-bin/priority.php
 priority.php: ERROR: PRIORITY is not defined
   -- AGI Script priority.php completed, returning 0
   -- Executing NoOp("SIP/7000-fec2", "Priority is 3") in new stack


output should be
-----------------
   -- Executing NoOp("SIP/7000-fec2", "Priority is 1") in new stack
   -- Executing AGI("SIP/7000-fec2", "priority.php") in new stack
   -- Launched AGI Script /var/lib/asterisk/agi-bin/priority.php
 priority.php: priority is _2_
   -- AGI Script priority.php completed, returning 0
   -- Executing NoOp("SIP/7000-fec2", "Priority is 3") in new stack
Comments:By: Tilghman Lesher (tilghman) 2005-07-19 16:18:34

Builtin variables are already defined in your object.  If they aren't, it's a bug in the library you're using, not in Asterisk.