[SR-Users] subst_hf with capture groups
Daniel-Constantin Mierla
miconda at gmail.com
Tue Apr 28 09:05:36 CEST 2015
Hello,
the tracker on github project:
- https://github.com/kamailio/kamailio/issues
Cheers,
Daniel
On 28/04/15 07:28, Igor Potjevlesch wrote:
>
> Hello Daniel,
>
>
>
> It works fine like this, thank you.
>
>
> Can you tell me where I can open a tracker?
>
>
>
> Regards,
>
>
>
> Igor.
>
>
>
> *De :*sr-users [mailto:sr-users-bounces at lists.sip-router.org] *De la
> part de* Daniel-Constantin Mierla
> *Envoyé :* lundi 27 avril 2015 16:37
> *À :* Kamailio (SER) - Users Mailing List
> *Objet :* Re: [SR-Users] subst_hf with capture groups
>
>
>
> Hello,
>
> try with:
>
> $var(x) = "33";
>
> subst_hf("P-Asserted-Identity", "/(.*\")0(.*)(.*\")/\1$var(x)\2\3/", "a");
>
> Also, open an issue on the tracker to investigate it properly and
> eventually come up with proper solution for it.
>
> Cheers,
> Daniel
>
> On 27/04/15 16:01, Igor Potjevlesch wrote:
>
> Hello,
>
>
>
> I can't figure out how to handle this case:
>
> subst_hf("P-Asserted-Identity", "/(.*\")0(.*)(.*\")/\133\2\3/", "a");
>
>
>
> I'd like to substitute with \1 followed with 33 but it looks like
> the substitution tries to be done with \133. The capture group
> \133 doesn't exist.
>
>
>
> I tried with the following syntax: /${1}33 but ${1} is interpreted
> as a string.
>
>
>
> Someone can help me? Thank you.
>
> Regards,
>
>
>
> Igor.
>
>
>
>
> _______________________________________________
>
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>
> sr-users at lists.sip-router.org <mailto:sr-users at lists.sip-router.org>
>
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> --
> Daniel-Constantin Mierla
> http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> - http://www.linkedin.com/in/miconda
> Kamailio World Conference, May 27-29, 2015
> Berlin, Germany - http://www.kamailioworld.com
--
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference, May 27-29, 2015
Berlin, Germany - http://www.kamailioworld.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20150428/9f6de5f4/attachment.html>
More information about the sr-users
mailing list