On Sun, 2010-02-28 at 04:00 +0800, D Tucny wrote: > Or, alternatively using the 's' priority... > > > exten => 845,1,Verbose(3, Incoming call from ${CALLERID(all)}) ; this > will be priority 1 > exten => 845/12345678,n,Goto(blacklist) ; the n will make this > priority 2 > exten => 845/23456789,s,Goto(blacklist) ; the s will make this also > priority 2 > exten => 845/34567890,s,Goto(blacklist) ; again, priority 2 > exten => 845/09876543,s,Goto(whitelist) ; and again > exten => 845/98765432,s,Goto(whitelist) ; and again > exten => 845/87654321,s,Goto(whitelist) ; and again > exten => 845,s,Verbose(3, CLI (${CALLERID(num)}) is neither > blacklisted or whitelisted) ; last s, so last priority 2, this time > with no pattern > exten => 845,n,Dial(SIP/somewhere,180) ; this will be priority 3 > exten => 845,n,Hangup() ; priority 4 > exten => 845,n(blacklist),Verbose(3, CLI (${CALLERID(num)}) is > blacklisted) ; priority 5 > exten => 845,n,Hangup(21) ; priority 6, cause code 21 = rejected > exten => 845,n(whitelist),Verbose(3, CLI (${CALLERID(num)}) is > whitelisted) ; priority 7 > exten => 845,n,Dial(SIP/somewhereelse,180) ; priority 8 > exten => 845,n,Hangup() ; priority 9 > > > You can see the priorities from the asterisk cli by doing a 'dialplan > show <context>'
Thanks. I've got it doing just what I want now :-) Appreciate your help. -- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users