[SR-Users] Remove all cpecial characters (\n, \t etc)from xml body

Daniel-Constantin Mierla miconda at gmail.com
Mon Oct 30 10:29:32 CET 2017


On 28.10.17 20:28, Yuriy Gorlichenko wrote:
> Hi. I building external presentity service for web based phones
> Main trouble that i have at the xml body of PUBLISH message \n \t
> characters and because of it can't set body as string to the redis
> So I trying to find a way to remove special characters form the xml
> body for get oneline string instead of multiline
> I use native .cfg file for now and, unfortunattely, can not use lua or
> phyton
> I tried 
> $var(body)=$(rb{s.rm,$var(RemoveThisStaff)}) where 
> $var(RemoveThisStaff) = "\n" and "\t"
> but it was unsuccesfull. Maybe someone will help to kno how to do it.
can you try with:




Not sure if needs double back slashes, that's why I said to try the both.


Daniel-Constantin Mierla
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training, Nov 13-15, 2017, in Berlin - www.asipto.com
Kamailio World Conference - www.kamailioworld.com

More information about the sr-users mailing list