[Asterisk-Dev] Callingcard (again, sorry!)

Terence Parker terence at parker.com.hk
Wed May 19 04:44:35 MST 2004


Hi there,

Thanks for the reply.

Regarding DeadAGI - I typed 'show application DeadAGI' but don't see 
anything different than I would get if I typed 'show application AGI' . 
Other than the mention of a different return code, I don't notice any 
difference between these two applications. Or is there really no 
difference? The warning message I get makes it sound as if I would 
actually benefit from using DeadAGI over AGI. I take it this does not 
help my call termination script though?

My other problem is that if a call is terminated in the middle of an 
AGI script (e.g. during the voice prompts) the PHP script continues. Is 
there any signal at all or anything which is sent to AGI applications 
which it could use to determine that a call has dropped? I'm not too 
sure how to use the hangup callback function to achieve this function.

Thanks,

Terence



On 19 May 04, at 12:41 PM, Eric Wieling wrote:

> On Tue, 2004-05-18 at 23:23, Terence Parker wrote:
>> app_agi.c:1511 agi_exec: If you want to run AGI on hungup channels you
>> should use DeadAGI!
>
> "show application DeadAGI"
>
>> 2. If find that if a call is terminated in the middle of a script, the
>> script will continue running. For example, currently my script reads 
>> out a
>> bunch of stuff to the user (you are calling x country, your card 
>> balance is,
>> you have x minutes for this call etc...) - if a user hangs up during 
>> that
>> the PHP script has no way of knowing and will continue to the end -
>> including adding a lock to the MySQL database and a timestamp. So upon
>> running the script again, the user will find their account locked.
>
> See the hangup callback function in the sample scripts at
> http://www.fnords.org/~eric/asterisk/downloads




More information about the asterisk-dev mailing list