<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix"><tt>Hello,<br>
        <br>
        The basic idea is to replace the RURI (via $ru variable) with
        the new SIP UTI destination. Where/how do you get this new
        destination, if up to the nature of your redirect logic. Like
        you can load it from DB, you can do a transformation via
        dialplan, you can do aliases (as Stefano suggested), etc<br>
        <br>
        Regards,<br>
      </tt>
      <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
      On 10.03.2014 10:42, Mike Claudi Pedersen wrote:<br>
    </div>
    <blockquote
cite="mid:CADats6Hg5ZWe0rQ-_TgTrBPXaY_C18LWcVS7HN9aUpShEA1mQQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">this makes no sense to me, im not sure alias is
        what i wanna use. i just want some method to redirect calls to
        another server, using a list of known users and locations</div>
      <div class="gmail_extra"><br>
        <br>
        <div class="gmail_quote">2014-03-10 9:32 GMT+01:00 Stefano
          Pisani <span dir="ltr">&lt;<a moz-do-not-send="true"
              href="mailto:stefano.pisani@omnianet.it" target="_blank">stefano.pisani@omnianet.it</a>&gt;</span>:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div text="#000000" bgcolor="#FFFFFF"> Simply replace the
              $ru ($ru = NEWURI) and the call goes to the right
              destination<br>
              <br>
              If the remapping is fixed you and use ALIAS. for example.<br>
              <br>
              <div>Il 10/03/2014 08.11, Mike Claudi Pedersen ha scritto:<br>
              </div>
              <blockquote type="cite">
                <div>
                  <div class="h5">
                    <div dir="ltr">Can someone please help me ind the
                      right direction, i need to implement a system to
                      rewrite the destination URI from a list of
                      possible destinations.
                      <div>eg</div>
                      <div>call from 20304050</div>
                      <div>&nbsp; &nbsp;<span>if(method == "INVITE") {</span>
                        <pre style="font-size:0.9em;font-family:'Lucida Console','Andale Mono','Courier New',Courier;margin-top:0px;margin-bottom:0px;padding:6px;border:1px solid rgb(235,235,235);background-color:rgb(251,254,250);color:rgb(102,102,102);line-height:21.593280792236328px">            "check where 20304050 is"</pre>
                        <div>
                          <div><br>
                          </div>
                          <div>then return and replace 20304050 with
                            something like <a moz-do-not-send="true"
                              href="tel:%2B4520304050"
                              value="+4520304050" target="_blank">+4520304050</a>@voip123.local
                            and redirect</div>
                          <div><br>
                          </div>
                          -- <br>
                          <div dir="ltr">Med venlig hilsen<br>
                            ipnordic A/S<br>
                            <div><br>
                            </div>
                            <div>Mike Claudi Pedersen</div>
                            <div>Tekniker</div>
                            <div>
                              <div><br>
                              </div>
                              Telefon:&nbsp;<span
style="color:rgb(61,58,54);font-family:aller_lightregular,Arial,Helvetica,sans-serif">79301033</span><br>
                              <a moz-do-not-send="true"
                                href="http://www.ipnordic.dk/"
                                style="color:rgb(17,85,204)"
                                target="_blank">www.ipnordic.dk</a></div>
                          </div>
                        </div>
                      </div>
                    </div>
                    <br>
                    <fieldset></fieldset>
                    <br>
                  </div>
                </div>
                <pre>_______________________________________________
Users mailing list
<a moz-do-not-send="true" href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a>
<a moz-do-not-send="true" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
              </blockquote>
              <br>
            </div>
            <br>
            _______________________________________________<br>
            Users mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
            <a moz-do-not-send="true"
              href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users"
              target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
            <br>
          </blockquote>
        </div>
        <br>
        <br clear="all">
        <div><br>
        </div>
        -- <br>
        <div dir="ltr">Med venlig hilsen<br>
          ipnordic A/S<br>
          <div><br>
          </div>
          <div>Mike Claudi Pedersen</div>
          <div>Tekniker</div>
          <div>
            <div><br>
            </div>
            Telefon:&nbsp;<span
style="color:rgb(61,58,54);font-family:aller_lightregular,Arial,Helvetica,sans-serif">79301033</span><br>
            <a moz-do-not-send="true" href="http://www.ipnordic.dk/"
              style="color:rgb(17,85,204)" target="_blank">www.ipnordic.dk</a></div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>