[asterisk-users] Extensions of sip trunk
Steve Edwards
asterisk.org at sedwards.com
Mon Jun 5 18:28:07 CDT 2017
On Tue, 6 Jun 2017, Hans-Peter Jansen wrote:
>>> I wonder, if I really need to grab the extension with
>>> Set(DN=${SIP_HEADER(TO):5}) or something similar?
>>
>> Yes, something like if they can't fix the R-URI:
>> exten => X_.,n,Set(TO=${CUT(SIP_HEADER(To),@,1)})
>> exten => X_.,n,Set(TO=${CUT(TO,:,2)})
>> exten => X_.,n,Goto(somewhereelsetopreventloops${TO},1)
>
> Sorry for the silly question, but how do I feed the TO variable back to the
> usual pattern matching? Assign to $EXTEN?
same = n, goto(${CONTEXT},${TO},1)
--
Thanks in advance,
-------------------------------------------------------------------------
Steve Edwards sedwards at sedwards.com Voice: +1-760-468-3867 PST
https://www.linkedin.com/in/steve-edwards-4244281
More information about the asterisk-users
mailing list