<p>Thk for the fast reply and for the help. :)</p><p> it worked :)<br /><br /><br />Nelson Silva
<br />-----------------
<br />email: nelson.silva@neuvex.com
<br />website: http://www.neuvex.com
<br /> <br /><br /><strong>On Mon Sep 26 11:24 , Daniel-Constantin Mierla sent:<br /><br /></strong><blockquote style="border-left: 2px solid rgb(245, 245, 245); margin-left: 5px; margin-right: 0px; padding-left: 5px; padding-right: 0px;">Hello,<br />
<br />
you can implement this with avpops module <br />
(<a target="_blank" href="../parse.pl?redirect=http%3A%2F%2Fwww.voice-system.ro%2Fdocs%2Favpops%2F%29.">http://www.voice-system.ro/docs/avpops/\).</a> Functions of interest for you <br />
are avp_write() and avp_pushto().<br />
<br />
...<br />
avp_write("1234", "s:client_n");<br />
<br />
alias_db_lookup("dbaliases"); <br />
<br />
lookup("location);<br />
<br />
avp_pushto("$ruri/username", "s:client_n");<br />
<br />
t_relay();<br />
<br />
...<br />
<br />
For optimization reasons, you may consider replacing the name of avp <br />
"s:client_n" to an integer id, e.g., "i:500" (faster operations).<br />
<br />
Cheers,<br />
Daniel<br />
<br />
<br />
On 09/26/05 14:14, Nelson Silva wrote:<br />
<br />
> Have been using openser for a couple of months and i run into a problem.<br />
><br />
> Currently i'm using alias_db_lookup, location and t_relay to do the <br />
> routing.<br />
><br />
> Since many clients have many numbers, i need to to rewrite the contact <br />
> to the right client. It's doing it but only for a client with one <br />
> number. Need for clients with more numbers.<br />
><br />
> This is what i want:<br />
><br />
> <br />
> $client_n = 1234<br />
><br />
> alias_db_lookup("db_aliases"); -> <a href="javascript:top.opencompose('client_number@provider.com','','','')">client_number@provider.com</a><br />
><br />
> location("location"); -> <a href="javascript:top.opencompose('client_number@client','','','')">client_number@client</a>_ip<br />
><br />
> rewriteuser($client_n);<br />
><br />
> t_relay(); <br />
><br />
> This is what i have:<br />
><br />
> alias_db_lookup("dbaliases"); <br />
><br />
> lookup("location);<br />
><br />
> t_relay();<br />
><br />
> <br />
><br />
> Anyone have this implemented? <br />
><br />
><br />
> Nelson Silva<br />
> -----------------<br />
> email: <a href="javascript:top.opencompose('nelson.silva@neuvex.com','','','')">nelson.silva@neuvex.com</a><br />
> website: <a target="_blank" href="../parse.pl?redirect=http%3A%2F%2Fwww.neuvex.com">http://www.neuvex.com</a><br />
><br />
><br />
>------------------------------------------------------------------------<br />
><br />
>_______________________________________________<br />
>Users mailing list<br />
><a href="javascript:top.opencompose('Users@openser.org','','','')">Users@openser.org</a><br />
><a target="_blank" href="../parse.pl?redirect=http%3A%2F%2Fopenser.org%2Fcgi-bin%2Fmailman%2Flistinfo%2Fusers">http://openser.org/cgi-bin/mailman/listinfo/users</a><br />
> <br />
><br />
</blockquote></p><BR>