[OpenSIPS-Users] Script variable manipulation

Jose Silva joesilvas at gmail.com
Fri Jun 8 14:37:48 CEST 2012

Hi Vlad,

Thanks for the fast reply.
I have looked at these documents, but it seams that I will not be able to
achieve what I expected (or I might not be understanding correclty the
documentation). For example if I want to get a part of SIP URI userpart,
but this information can be vary in size, the only way I see to get this
would be with a some match of a regular expression ([+]351)?(\d{9})(\d+)
that would match with the syntax I expect on the userpart. But from what I
see on the docs, it seams that I can not have this much flexability with
the variables (only with AVPs). But I am trying to avoid the AVPs.

Best Regards,
José Carlos Silva

2012/6/6 Vlad Paiu <vladpaiu at opensips.org>

> **
> Hello,
> Check out the string [1] and uri [2] transformations. For accesing a
> specific header, see the $hdr variable.
> [1] http://www.opensips.org/Resources/DocsCoreTran15#toc1
> [2] http://www.opensips.org/Resources/DocsCoreTran15#toc17
> [3] http://www.opensips.org/Resources/DocsCoreVar15#toc82
> Regards,
> Vlad Paiu
> OpenSIPS Developerhttp://www.opensips-solutions.com
> On 06/06/2012 06:03 PM, Jose Silva wrote:
>  Hello all,
> I'm using opensipps 1.5.3 and I'm not understanding how I can store a
> substring of a header/SIP URI on a script variable. I have searched the
> documentation and it seams that this is not possible, can you confirm?
> ex.
> $var(x)= store the middle part of SIP URI userpart
> $var(x)= store a specific parameter present on the SIP URI
> Best Regards to all,
> José Carlos Silva
> _______________________________________________
> Users mailing listUsers at lists.opensips.orghttp://lists.opensips.org/cgi-bin/mailman/listinfo/users
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20120608/f5e21ebf/attachment.htm>

More information about the Users mailing list