[asterisk-users] Get back in dialplan with number-parsing

Leif Neland leifn at neland.dk
Fri Dec 4 08:15:30 CST 2009


I'd like to put a phone in a special context, where a test is made on its business hours, then if so, proceed to the normal context to do whatever it does with outgoing and local calls.

I've tried, just to go from one context to the next: 
[specialoutgoing]
exten => _X.,1,noop(This is a special content)
exten => _X.,n,gotoiftime(....?forbidden,1)
exten => _X.,n,goto(outgoing,${CALLERID(dnid)},1)

I use _X. to match anything, but if the call is allowed, I want to jump back in the [outgoing] context and restart parsing the dialled number.

exten => _X.,n,goto(outgoing,${CALLERID(dnid)},1)
works only id the dialled extension exists precicely in outgoing context, not in included contexts, and does not to pattern matching.

I can't include [outgoing] in [specialoutgoing], because the number has already been matched by _X.

I don't want to rewrite the whole dialplan in [specialgoing] or to put the test into the existing contexts.

Leif


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


More information about the asterisk-users mailing list