<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2604" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hi guys,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I'm experiencing troubles w/ dial plans. Here
is part of my ser.cfg :</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>if (is_user_in("From",
"pstn-allowed")){<BR> if (uri=~"^sip:0")
{<BR>
strip(0);<BR>
t_relay();<BR> log(0,
"**************** LOCAL
***************\n");<BR>
break;<BR>
break;<BR> break;<BR> } else
{<BR>if (uri=~"^sip:[1-9]") {<BR>
log(0, "\n\n************ PSTN ***********\n");</FONT><FONT
face=Arial size=2><BR>
rewritehostport("xx.xx.xx.xx:5060");<BR>
append_branch("xx.xx.xx.xx");<BR>
t_relay();<BR>
t_relay_to_tcp("xx.xx.xx.xx",
"5060");<BR> log(0,
"********************************************\n\n\n");<BR>
break;<BR> };</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>
};<BR></FONT></DIV>
<DIV><FONT face=Arial size=2>When I call local user 123456 this way 0123456
( 0 is the prefix ) it's forwarded to the pstn gw???!!! </FONT></DIV>
<DIV><FONT face=Arial size=2>If I call any pstn number it works fine... only
internal calls doesn't work the way they have to. </FONT> </DIV>
<DIV><FONT face=Arial size=2>Somebody can tell me where's the problem.
</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Thanks in advance!</FONT><FONT face=Arial
size=2></DIV>
<DIV><BR></DIV></FONT></BODY></HTML>