Thanks very much Alex.
On 08/14/2014 02:59 PM, AliReza Khoshgoftar Monfared wrote:
Hi list,
How can I extract a specific part of my message body?
I know that "textops" has the function "search_body(re)" but it returns
True/False upon finding "re" in the body of the text, how can I return
the actual text that regular expression matches?
As an example, my message body is
rate is 172#012
I want to extract the number "172" out of this.
There is no general means of accomplishing that. Your best bet is to feed the message body to another language using one of the language interface modules, such as Lua, Perl or Python, and parse stuff out of it there.
For all of its features, Kamailio route script is not a general-purpose programming runtime.
--
Alex Balashov - Principal
Evariste Systems LLC
Tel: +1-678-954-0670
Web: http://www.evaristesys.com/, http://www.alexbalashov.com/
Please be kind to the English language:
http://www.entrepreneur.com/article/232906
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users