[Asterisk-Users] Invalid Extensions -- More like traditional
PBX systems?
Stephen Rosebush
srosebush at desynched.org
Wed Jun 16 12:32:19 MST 2004
haha that worked like a charm. thanks.
Brian D'Arcy wrote:
>Steve,
>
>What I had problems using 'i' also, what worked for me was the
>following...
>
>For example, I have a bunch of extensions I'm matching on in a
>particular context. Keep in mind, the stdexten macro you see below is
>not defined properly, and is for example only.
>
>[extensions]
>exten => 3201,1,Macro(stdexten)
>exten => 3202,1,Macro(stdexten)
>exten => 3203,1,Macro(stdexten)
>exten => 3204,1,Macro(stdexten)
>exten => 3205,1,Macro(stdexten)
>exten => 3206,1,Macro(stdexten)
>
>exten => _XXXX,1,Answer
>exten => _XXXX,2,Wait(1)
>exten =>
>_XXXX,3,Playback(/usr/src/test/asterisk-sounds/sounds/jedi-extension-tri
>ck)
>exten =>
>_XXXX,4,Playback(/usr/src/test/asterisk-sounds/sounds/please-try-again)
>exten => _XXXX,5,Read(NUMBER,,4)
>exten => _XXXX,6,Goto(${NUMBER}|1)
>
>What happens is, after all of your possibly matchs have failed (since it
>matches top to bottom in the context), it catches the _XXXX (match all)
>extension, which I consider to be invalid, since it matched none of my
>defined entries above it.
>
>>From there you can do whatever you want with the call. In my case, I
>decided to have some fun. =)
>
>Brian D'Arcy
>
>-----Original Message-----
>From: asterisk-users-admin at lists.digium.com
>[mailto:asterisk-users-admin at lists.digium.com] On Behalf Of Stephen
>Rosebush
>Sent: Wednesday, June 16, 2004 10:45 AM
>To: asterisk-users at lists.digium.com
>Subject: Re: [Asterisk-Users] Invalid Extensions -- More like
>traditional PBX systems?
>
>Yes but I try that and it doesnt even go to it, I am trying to have the
>invalid handler be executed when the extension a user tries to dial from
>
>the SIP phone is not in any of the contexts (non-existant)... I've tried
>
>this and placed it in several contexts and it does not work.
>
>Steve
>
>Rob Fugina wrote:
>
>
>
>>On Wed, Jun 16, 2004 at 11:35:45AM -0300, Ray Burkholder wrote:
>>
>>
>>
>>
>>>Set up a general pattern match with the message and congestion.
>>>
>>>Extension pattern matching looks for the most specific match in any
>>>
>>>
>one
>
>
>>>context. So if a specific extension is not found, it will take the
>>>general pattern.
>>>
>>>
>>>
>>>
>>Wouldn't it be a little better to use the special 'invalid extension'
>>extension -- 'i'? Something like...
>>
>>exten => i,1,Playback(invalid)
>>exten => i,2,Busy
>>
>>Rob
>>
>>
>>
>>
>>
>
>
>
>
--
Stephen Rosebush,
srosebush at desynched.org
http://www.desynched.org/
// Hardline // IP Phone
USA: 1-248-724-4452 x201 FWD: 63420 x201
Netherlands: +31-(0)20-6598858 x63420 x201 IAXTEL: 1-700-356-6191 x201
United Kingom: +44-(0)870-3403054 x201 SIP: sip:srosebush at desynched.org
More information about the asterisk-users
mailing list