On Fri, 2007-11-16 at 22:58 -0600, Eric "ManxPower" Wieling wrote:
> exten => _0111NXXNXXXXXX,1,Goto(${EXTEN:4},1)
> 
> exten => _NXXNXXXXXX,1,Dial(....

Of course!  Couldn't be any simpler.  Almost!

User dials 6135551212, phone sends 01116135551212, above rules processes
as:

Goto(6135551212,1)

Fair enough.

User dials 16045551212, phone sends 01116045551212, above rules process
as:

Goto(6045551212,1)

Bzzzt.  "You must dial a 1 before long distance calls".

It's not as easy as just using "613" as a qualifier for LD or not, as
some 613 is local, and some is not.  Certainly, a list of rules such as:

exten => _0111613abcXXXX,1,Goto(${EXTEN:4},1)

Where there is one of those for every "abc" that is a local exchange
followed by:

exten => _0111NXXNXXXXXX,1,Goto(${EXTEN:3},1)

would work, but that seems even more nasty than my original problem.

Indeed, it seems I need to be able to do some sort of lookup into a
database to see if "abc" is a local exchange or not (let's assume that I
can populate a database with local exchanges).

Thots?

b.



_______________________________________________
--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

Reply via email to