[OpenSER-Users] Replacing "." of a domain with "_" and store the result in a variable

Iñaki Baz Castillo ibc at in.ilimit.es
Thu Aug 2 17:24:27 CEST 2007


Hi, I just need to take the requested domain $rd and store in a variable that 
domain but with . replaced by _:

  sip.domain.org  ->  sip_domain_org

This is because I want tables in MySQL containing the domain name but MySQL 
don't allow . in table name.

So now, what should I do for that? I really thought "textops" could help me 
but I don't see a function to replace text and store it in a variable.

I see "replace()" and "subst()" but they seem to exist for replacing text in 
the SIP message "on the fly", that is not that I'm looking for.

Any suggestion? Thanks a lot.


-- 
Iñaki Baz Castillo
ibc at in.ilimit.es




More information about the Users mailing list