[Asterisk-Users] extension matching using includes...errornous results

Iqbal iqbal at gigo.co.uk
Fri Jul 22 11:24:58 MST 2005


Hi

I have the following simple test scenario

[from-sip]
include => ext-matchall
include => ext-match98andrecord

; match 6 digits
[ext-matchall]
exten => _XXXXXX,1,SetVar(FEE=${DNID}) ;line 1
exten => _XXXXXX,2,Macro(vm-eachuser)  ;line2


[ext-match98andrecord]
;here we should fire the query to get the correct context which in this 
case should be 500
exten => _98.,1,StripMSD,2  ;line 3
exten => _X.,2,SetVar(NEWNUM=${EXTEN}) ;line 3
.....

Now when a call comes in the uri is 98123456, hence from what I think it 
should hit the ext-match98andrecord, which it does, it strips the first 
2 digits....and then jumps and follows ext-matchall, and goes to the 
Macro(vm-eachuser). Now I thought by including these in the main 
context, I could get the order correct, i.e do line 3 then line 4, not 
line 3, line 2

any pointers, ideas, better way of doing it

iqbal




More information about the asterisk-users mailing list