[SR-Users] how to get value of route param?
Daniel-Constantin Mierla
miconda at gmail.com
Mon Mar 10 09:02:30 CET 2014
Hello,
On 10/03/14 06:18, Juha Heinanen wrote:
> rr module has check_route_param(re) function that can be used to check
> if local route header has a param that matches re. however, there does
> not exist a function to find out what is the value of a given rr param.
> for example, if route header has param ;param=foo, how to extract value
> foo of param?
>
> there is @rr.uri.params select that together with {param.value,name}
> transformation might be able to do the job?
>
this should work, provided you use $sel(rr.uri) -- iirc, transformations
cannot be applied directly to @xyz
The alternative is to use the tobody transformation to get the parts of
the route header, then param transformation.
Cheers,
Daniel
--
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference - April 2-4, 2014, Berlin, Germany
http://www.kamailioworld.com
More information about the sr-users
mailing list