[cisco-voip] translation rule
Michael Thompson
mthompson729 at gmail.com
Wed Aug 13 12:01:57 EDT 2008
Ryan,
Yes, I think the proper format would move the ^ to the first match,
such as:
voice translation-rule 1
rule 1 /^660825\(..\)/ /26\1/
meaning any number starting with 660825, take the next 2 digits after the 5
and make them 'set1'. Replace that number with the literal string 26(set1).
The whole config set would go like such:
voice translation-rule 1
rule 1 /^660825\(..\)/ /26\1/
Voice translation-profile Sub26 <-(this is just a label, call it what you
like)
Translate called 1
Voice-port 0/0/1:23
Translation-profile incoming Sub26
OR INSTEAD OF VOICE PORT
Dial-peer voice 1 pots
Translation-profile incoming Sub26
A good reference for how to build some of this:
http://www.cisco.com/en/US/tech/tk652/tk90/technologies_configuration_exampl
e09186a00803f818a.shtml
-----Original Message-----
From: cisco-voip-bounces at puck.nether.net
[mailto:cisco-voip-bounces at puck.nether.net] On Behalf Of Ryan West
Sent: Wednesday, August 13, 2008 11:53 AM
To: Joe Cisco; eng_hady1 at yahoo.com
Cc: cisco-voip at puck.nether.net
Subject: Re: [cisco-voip] translation rule
Does the search and replace function work with a regexp in the replace
section? I would have thought the ^ belonged in the 660825 part, meaning to
search for a string that starts with 66. Were you able to produce a working
result using test voice translation rule 1 66082555?
-ryan
-----Original Message-----
From: cisco-voip-bounces at puck.nether.net
[mailto:cisco-voip-bounces at puck.nether.net] On Behalf Of Joe Cisco
Sent: Wednesday, August 13, 2008 8:33 AM
To: eng_hady1 at yahoo.com
Cc: cisco-voip at puck.nether.net
Subject: Re: [cisco-voip] translation rule
Wait, sorry, scratch that... that was wrong. (too early in the morning)
!
voice translation-rule 1
rule 1 /660825\(..\)/ /^26\1/
!
-Joe C.
On Wed, Aug 13, 2008 at 6:04 AM, hady salah ashour <eng_hady1 at yahoo.com>
wrote:
> Hi guys,
>
> I want configure translation rule that do the following :
> translate range from 66082500 to 66082599
>
> to this range from 2600 to 2699
>
> For example convert 66082509 to 2609 and so on copy the last 2 digits
> Dialed String and put it after 26
>
> please i need a help from you to do that.
>
> Thanks.
> Hady Salah ,
>
>
> _______________________________________________
> cisco-voip mailing list
> cisco-voip at puck.nether.net
> https://puck.nether.net/mailman/listinfo/cisco-voip
>
>
_______________________________________________
cisco-voip mailing list
cisco-voip at puck.nether.net
https://puck.nether.net/mailman/listinfo/cisco-voip
_______________________________________________
cisco-voip mailing list
cisco-voip at puck.nether.net
https://puck.nether.net/mailman/listinfo/cisco-voip
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://puck.nether.net/pipermail/cisco-voip/attachments/20080813/9c9fad46/attachment.html>
More information about the cisco-voip
mailing list