From: "Thomas Patterson" <[EMAIL PROTECTED]>
Date: Mon, 12 Mar 2007 19:03:12 +1300
I have setup my Asterisk server to have 3 outbound routes
1 being for local calls
2 being for toll calls
3 being international call
What I am wanting to do is automaticly setup if you dial a local number it
goes out on the local interface
If you dial a toll call it will go out on the tall provider.
Now for the 3 option I want it to pick up the slack of the other eg if I
have not put the dialing prefix in it will default to this trunk
Just match your local numbering plan. Don't know your country's, but in
North America (NANP), you can do
[general]
NANP = NXXNXXXXXX; "10-digit phone number starting with area code"
NA_LOCAL = NXXXXXX; a North American local #
[outgoing]
exten => _${NA_LOCAL},1,NoOp(Got local number ${EXTEN})
exten => _${NA_LOCAL},n,Dial(Zap/g1/${EXTEN}); G1 is for local
exten => _${NANP),1,Goto(1${EXTEN}); for the lazy people
exten => _1${NANP},1,NoOp(Got toll number ${EXTEN})
exten => _1${NANP},n,Dial(Zap/g2/${EXTEN}); G2 is for toll
exten => _X.,1,NoOp(Likely international number ${EXTEN})
exten => _X.,1,Dial(Zap/g3/${EXTEN}); G3 is for international
Of course the real thing is a bit more complicated, if you want to count for
"local toll" and toll-free numbers, etc.
Yuan Liu
Any help would be greatfull
Thomas Patterson
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users