Thanks Norm,<br><br>That is exactly what I am looking for. It solved my problem. I used the prefix to identify calls that should be routed to a particular carrier by Openser. But this added prefix affects the interop with some applications with the carrier, hence the need to strip off the tags i added.
<br><br>Rgds,<br><br>Tolu<br><br><div><span class="gmail_quote">On 8/18/07, <b class="gmail_sendername">Norman Brandinger</b> <<a href="mailto:norm@goes.com">norm@goes.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Perhaps the "uac_replace_from()" function is what you are looking for.<br><br>Note
that modifying the "From:" header is NOT allowed by the standards. Please review
the mailing lists in regard to this topic as it's been discussed many times.<br><br>OpenSER
gives you enough control to "shoot yourself in the foot". It it possible to create
a configuration that can solve your "internal business situation" but might cause
interoperability problems with others.<br><br>Regards,<br>Norm <div><span class="e" id="q_1147951d46a84ec3_1"><br><br><br><br>> Hi Norm, <br>> <br>> Thanks for the quick response. <br>> <br>> I was
able to use s.substr to perform the string transformations and I got <br>> the correct value.
However, what I am really trying to do is to actually <br>> re-write the PV ($fU) with the
result of s.substr. <br>> <br>> For example, I want ($fU) be assigned the value
$(fU{s.substr,3,0}); and <br>> this new value be used as my from_uri; and hence my CallerID.
<br>> <br>> Thanks again. <br>> <br>> Tolu <br>> <br>> On 8/18/07,
Norman Brandinger <<a href="mailto:norm@goes.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">norm@goes.com</a>> wrote: <br>>> <br>>> Take a look at the
following documentation. Take special note of 'substr' <br>>> <br>>>
<a href="http://openser.org/dokuwiki/doku.php/transformations:1.2.x" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://openser.org/dokuwiki/doku.php/transformations:1.2.x</a> <br>>> <br>
>> Regards,
<br>>> Norm <br>>> <br>>> <br>>> > Hi all, <br>>> >
<br>>> > I am trying to re-write the from_uri ($fU) for all calls coming from my <br>>> > Asterisk server before sending it to the PSTN. I usually prefix the ANI <br>>> in <br>>> > asterisk with "222" to route it to openser, and then
openser simply <br>>> > forwards the call to the PSTN. The problem is that 222+ANI
appears as my <br>>> <br>>> > caller id and is unacceptable. Can anyone give me
hint to strip out this <br>>> <br>>> > prefix in openser. <br>>> >
<br>>> > Thanks. <br>>> > <br>>> > Tolu <br>>> >
_______________________________________________ <br>>> > Users mailing list <br>>> > <a href="mailto:Users@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Users@openser.org
</a> <br>>> >
<a href="http://openser.org/cgi-bin/mailman/listinfo/users" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://openser.org/cgi-bin/mailman/listinfo/users</a> <br>>> > <br></span></div>
</blockquote></div><br>