Dialplan General Extension

Hello,

Is there any way in the Asterisk dial plan to execute a subroutine for all calls made in one or multiple contexts?

For ex. i have the following context:

[guest-1]
include = Common_Codes
include = Internall_Calls
include = RS-Module
include = Blocked_Dest
include = Oubound_Calls

[Common_Codes]
exten => 88,1,NoOp(Checking Voicemail)
same => n,Gosub(VoiceMail_Menu,start,1(${CALLERID(num)},${VM_Context}))
same => n,Hangup()

Where each include have their own extension. Now, i want to execute a subroutine for every call indifferent of the called extension. I tried the following code:

exten => _+X.,1,GoSub(Homer,start,1)

include = Common_Codes
include = Internall_Calls
include = RS-Module
include = Blocked_Dest
include = Oubound_Calls

But this is not going to work because ext ‘+X.’ will overlap the first extension in all includes. So, the only way to achieve that is to add ‘exten => 88,1,GoSub(Homer,start,1)’ in each include context, but i just wonder if this could be done generally for all includes.

Thanks.

You could make everything else start at priority 2, however that would man that every possible number beginning with + would be considered valid.

You could also have priority and 3 for each extension and make the subroutine call priority 2.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.