HI Răzvan ,

here is a link to sip trace and opensips log: http://pastebin.com/tkVmeVxa

Counter is 2, so for array 0 and 1:)

Outside are send only invites for one branch.

Br,
Miha

Dne 8/20/2013 3:11 PM, piše Răzvan Crainea:
Hi, Miha!

I am not sure what you're problem is. Can you tell me what's the value of $avp(counter)? How many "counter: ..." logs do you see and how many branches are created? Can you take a trace and count exactly how many INVITEs are sent out with different R-URI?

Best regards,

Răzvan Crainea
OpenSIPS Core Developer
http://www.opensips-solutions.com

On 08/20/2013 02:27 PM, Miha wrote:
Hi Răzvan,

I am doing now like this:

$avp(counter)= counter is for size of sql query to know, how many times
I need to loop this.

$var(i)=0;
                 while($var(i)<$avp(counter))
                 {
                 append_branch();
                 $ru="sip:" + $(avp(username)[$var(i)]) + "@" +
"xxx.xxx.xxx.xxx:5060";
                 xlog("counter: $var(i) ... username:
$(avp(username)[$var(i)])");
                 $var(i)=$var(i)+1;
                 }

I am getting a lot of invies for one call, but just first number from
array.

thx!

miha


Dne 8/20/2013 1:25 PM, piše Miha:
Hi Răzvan,

that I did:)

thank you for your help!

miha



Dne 8/20/2013 12:35 PM, piše Răzvan Crainea:
Hi, Miha!

According to the documentation, the second branch is created when
calling append_branch(), so yes, there will be two branches.

$ru pseudo-variable requires a URI, not an username. If you want to
change only the username part, you should use the $rU pseudo-variable:

...
append_branch();
$rU = C;
...

Best regards,

Răzvan Crainea
OpenSIPS Core Developer
http://www.opensips-solutions.com

On 08/20/2013 12:16 PM, Miha wrote:
HI Răzvan,


I am trying to implement this:
http://www.opensips.org/Documentation/Script-CoreFunctions#toc2

2. append_branch()

So if I do $ru=C instead of seturi("sip:C@domain"); this will do the
same?

Will there be two branches?

Br,
Miha




Dne 8/20/2013 12:07 PM, piše Răzvan Crainea:
Hi, Miha!

You cannot use pseudo-variables in the seturi() function. However, you
can use the $ru pseudo-variable to construct the R-URI.

Best regards,

Răzvan Crainea
OpenSIPS Core Developer
http://www.opensips-solutions.com

On 08/20/2013 10:04 AM, Miha wrote:
Hi,

how can I use pseude variable in seturi?

I am doing append_branch() and than seturi() but in set uri I
would like
to avps, so that this would be dynamically.

thx!

Miha





_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

Reply via email to