[asterisk-users] Sticky Park

Mat Murdock mmurdock at kimballequipment.com
Thu Aug 27 15:35:41 CDT 2009


C. Chad Wallace wrote:
> At 11:52 AM on 27 Aug 2009, Mat Murdock wrote:
>
>   
>> [parkedcallstimeout]
>>
>> exten => _SIP011XX,1,Answer()
>> exten => _SIP011XX,n,NoOp(Call Parked on: ${PARKINGSLOT})
>> exten => _SIP011XX,n,NoOp(This is who parked us: ${EXTEN})
>> exten => _SIP011XX,n,Set(PARKINGEXTEN=${PARKINGSLOT})
>> ;This sets the PARKINGEXTEN to the parking slot we were parked in.
>> exten => 
>> _SIP011XX,n,Dial(SIP/${EXTEN:4:4},${RINGTIMER},${INTERNAL_DIAL_OPTIONS})
>> ;This send the call back to the person who parked it.  There are a 
>> couple of global variables I use here.  Nothing unusual here.
>>
>>
>> So what is the problem?  Well the problem is that the PARKINGEXTEN 
>> variable gets reset after the dial command in parkedcallstimeout.
>> That makes it so I cannot find out where that call was originally
>> parked  If I can find out how to get that little bit of information
>> when the call is re-parked then I think this will work.  If anyone
>> has any suggestions on how to accomplish this I would be grateful.
>>     
>
> Have you tried prefixing PARKINGEXTEN with '__' (two underscores) on
> the Set call in parkedcallstimeout?  That makes it a persistent
> variable, which will be inherited by sub-channels, like after a Dial.
>
> exten => _SIP011XX,n,Set(__PARKINGEXTEN=${PARKINGSLOT})
>
> You might only need one underscore. 
> For more info, see 'core show application set'.
>
>
>   

Perfect.  That did the job!  Now I have "Sticky Park"!!

Mat

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090827/40422d71/attachment.htm 


More information about the asterisk-users mailing list