<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"><span>Hello Alex, thank you. So this is what I have:</span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span><br></span></div><div style="background-color: transparent;">if (is_method("INVITE")) {</div><div style="background-color: transparent;">                xlog("L_DBG", "LOG: INVITE in PSTN route\n");</div><div style="background-color: transparent;">                $var(new_uri) = "sip:"+ "8888888888" +"@home.otv.net:5060";</div><div style="background-color: transparent;">                <span
 style="font-weight: bold;">uac_replace_from("","$var(new_uri)");</span></div><div style="background-color: transparent;">                xlog("L_DBG", "LOG: After update fU is $fU");</div><div style="background-color: transparent;"><br></div><div style="background-color: transparent;">                if (uri=~"sip:1[2-9][0-9]+@.*") {</div><div style="background-color: transparent;">                        if (!is_user_in("From", "ld")) {</div><div style="background-color: transparent;">                                xlog("LOG: PSTN call but user don't have permissions\n");</div><div style="background-color: transparent;">                               
 sl_send_reply("403", "No permission for long dist calls");</div><div style="background-color: transparent;">                                exit;</div><div style="background-color: transparent;">                        }</div><div style="background-color: transparent;">                }</div><div style="background-color: transparent;"><span></span></div><div style="background-color: transparent;">        }</div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"><br></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;">My questions are:</div><div style="font-family: 'times new roman', 'new york', times, serif;
 font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><br></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;">1. <span style="font-weight: bold;">When I do</span> <span style="font-weight: bold;">uac_replace_from("8888888888",""); I do not see any change in the output, my from user still remains the same and is not updated to 8888888888, why is that?</span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span style="font-weight: bold;"><br></span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span style="font-weight: bold;">2. When I run the scrip as shown in my
 snippet above the from user changes on the receiving phones caller id to 8888888888 but how come in my xlog I still see the old $fU and not the updated one?</span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span style="font-weight: bold;"><br></span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span>Thanks for the help.</span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span><br></span></div><div style="font-family: 'times new roman', 'new york', times, serif; font-size: 16px; color: rgb(0, 0, 0); background-color: transparent; font-style: normal;"><span>A</span></div>  <div style="font-family:
 'times new roman', 'new york', times, serif; font-size: 12pt;"> <div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"> <div dir="ltr"> <hr size="1">  <font size="2" face="Arial"> <b><span style="font-weight:bold;">From:</span></b> Alex Balashov <abalashov@evaristesys.com><br> <b><span style="font-weight: bold;">To:</span></b> arun Jayaprakash <jayaprakasharun@yahoo.com>; Kamailio (SER) - Users Mailing List <sr-users@lists.sip-router.org> <br> <b><span style="font-weight: bold;">Sent:</span></b> Thursday, August 22, 2013 4:08 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [SR-Users] Change "from user "<br> </font> </div> <div class="y_msg_container"><br><div id="yiv4553741765"><div>uac_replace_from() in the uac module can do that. <br><br><div class="yiv4553741765gmail_quote">arun Jayaprakash <jayaprakasharun@yahoo.com> wrote:<blockquote class="yiv4553741765gmail_quote"
 style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex;">
<div style="color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"><div>Hello, can someone let me know how I can modify the "from user" when making an outbound PSTN call. For example, when I make a PSTN call now the caller ID shows up as my 4 digit extension but I would like my PSTN number displayed instead. Thank you.</div><div><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: 'times new roman', 'new york', times, serif; background-color: transparent; font-style: normal;">Arun<br></div></div><pre class="yiv4553741765k9mail"><hr><br>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>sr-users@lists.sip-router.org<br><a rel="nofollow" target="_blank" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><br></pre></blockquote></div><br>
--<br>
Sent from my Nexus 10, with all the figments of autocorrect that might imply.<br>
<br>
Alex Balashov - Principal<br>
Evariste Systems LLC<br>
235 E Ponce de Leon Ave<br>
Suite 106<br>
Decatur, GA 30030<br>
United States<br>
Tel: +1-678-954-0670<br>
Web: <a rel="nofollow" target="_blank" href="http://www.evaristesys.com/">http://www.evaristesys.com</a>/, <a rel="nofollow" target="_blank" href="http://www.alexbalashov.com/">http://www.alexbalashov.com/</a></div></div><br><br></div> </div> </div>  </div></body></html>