[asterisk-users] exten => h,n,AGI(generateCall.php,${NEXT})

Christopher Harrington chris at acsdi.com
Wed Feb 20 09:41:44 CST 2013


On Wed, Feb 20, 2013 at 9:23 AM, Mahendra Dobariya <
mahendra_mahendra at hotmail.com> wrote:

>  File: /etc/asterisk/extensions.conf
> [call]
> exten => call,1,Answer
> exten => call,n,Playback(hello-world)
> exten => call,n,Hangup()
>
> exten => h,1,Set(NEXT=$[${NEXT}+1])
> exten => h,n,AGI(generateCall.php,${NEXT})
>

Try
exten =>
h,n,AGI(/usr/bin/php,/usr/share/asterisk/agi-bin/generateCall.php,${NEXT})


> exten => h,n,Hangup()
>




> <Dongle/dongle0-010000000d>AGI Rx << Could not open input file: 1
>
>
This is indicating that, for whatever reason, php is seeing "1" as argv[1],
not the name of your script file. I reproduced this by making a php shebang
that looks like
#!/usr/bin/php 1

Not sure why, though. The above should be a workaround for now.

-- 
-Chris Harrington
ACSDi Office: 763.559.5800
Mobile Phone: 612.326.4248
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20130220/5addc5a7/attachment.htm>


More information about the asterisk-users mailing list