[Asterisk-Users] Handling invalid extensions

William Glynn wglynn at freedomhealthcare.org
Fri Aug 20 09:57:13 MST 2004


Hrm:

> [extensions]
> exten => 950X,Macro(siphandset,${EXTEN})
> exten => 951X,Macro(siphandset,${EXTEN})
> exten => 9521,Macro(siphandset,${EXTEN})
> exten => 9537,Macro(siphandset,${EXTEN})
> exten => 9543,Macro(siphandset,${EXTEN})
> ; ...
> ; define patterns matching all assigned extensions
> 
> [inbound]
> ; Attempt to connect to extensions/xxxx
> exten => _123495XX,1,Dial(Local/${EXTEN:4}@extensions)
> 
> ; Didn't work? Connect to 9500
> exten => _123495XX,2,Goto(extensions,9500,1)

I guess that's a bit silly, now isn't it? :-)
Let's try that again:

[extensions]
exten => 9500,...
; ...
; all phones here

; No patterns matched?
exten => i,Goto(9500,1)

[inbound]
; Unconditionally hand off to [extensions] context
exten => _123495XX,Goto(extensions,${EXTEN:4},1)

--Will Glynn
Freedom Healthcare Group



More information about the asterisk-users mailing list