[OpenSIPS-Users] trying to rewriteuri to the value of a variable

Nigel Daniels nigel.daniels at connectandsell.com
Mon Feb 7 02:54:55 CET 2011


the '+ ' is for concatenation of the 2 strings  and $var(z) prints correctly
in the log

On Sun, Feb 6, 2011 at 5:45 PM, Duane Larson <duane.larson at gmail.com> wrote:

> Why do you have the + outside of the quotation marks when you are declaring
> var(z).  Wonder if that is your issue.  What is the output for your xlog
> that shows what varz is?
>
> Sent from Droid
> On Feb 6, 2011 7:37 PM, "Nigel Daniels" <nigel.daniels at connectandsell.com>
> wrote:
> > I tried the fallowing and $var(z) looks
> > $var(x)=$tu;
> > $var(y) = $(var(x){s.select,1,-});
> > $var(z) = "sip:"+$var(y);
> > xlog("$var(z)");
> > rewriteuri("$var(z)");
> >
> > This is what I get in the log
> >
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]: ERROR:core:parse_uri: bad
> > uri, state 0 parsed: <$var> (4) / <$var(z)> (7)
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]: ERROR:core:do_action: bad
> > uri <$var(z)>, dropping packet
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]: ERROR:core:parse_uri: bad
> > uri, state 0 parsed: <$var> (4) / <$var(z)> (7)
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]:
> > ERROR:core:parse_sip_msg_uri: bad uri <$var(z)>
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]: ERROR:tm:new_t: uri
> invalid
> > Feb 7 01:28:18 opensips /sbin/opensips[26561]: ERROR:tm:t_newtran: new_t
> > failed
> >
> >
> > My guess is that my syntax is incorrect or that this is not possible ,
> any
> > help is appreciated
> >
> > --
> > Nigel
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>


-- 
Nigel Daniels
Network & Systems Administrator
ConnectAndSell inc.
(650)-533-2542
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20110206/eb892b7b/attachment.htm>


More information about the Users mailing list