<div dir="auto">Try {s.unescape.user}<div dir="auto"><br></div><div dir="auto"><a href="https://www.kamailio.org/wiki/cookbooks/5.5.x/transformations#sescapeuser">https://www.kamailio.org/wiki/cookbooks/5.5.x/transformations#sescapeuser</a><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jul 14, 2022, 13:52 Benoit Panizzon <<a href="mailto:benoit.panizzon@imp.ch">benoit.panizzon@imp.ch</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi List<br>
<br>
Service Numbers, like to activate CFW probably often start with * and<br>
end with a #<br>
<br>
# is a special character that needs to be urlencoded in an SIP URI. So<br>
best would be to use a generic kamailio urldecode transormation. I guess<br>
{s.urldecode.param} is what I was looking for.<br>
<br>
So when I get a call to the 'enable CFW' service I get<br>
<br>
$rU => "*21+419999999%23"<br>
<br>
So I want to extract the destination number and remove the urlencoded # sign.<br>
<br>
So I do $var(cfw-dest) = <br>
$var(cfw-dest) = $rU;<br>
$var(cfw-dest) = $(var(cfw-dest){s.substr,3,0}); # "+419999999%23"<br>
$var(cfw-dest) = $(var(cfw-dest){s.urldecode.param});<br>
<br>
But now I end up with 419999999# the + sigh disappeared.<br>
<br>
Is this expected behavior? How would this be done the correct way?<br>
<br>
Mit freundlichen Grüssen<br>
<br>
-Benoît Panizzon-<br>
-- <br>
I m p r o W a r e A G - Leiter Commerce Kunden<br>
______________________________________________________<br>
<br>
Zurlindenstrasse 29 Tel +41 61 826 93 00<br>
CH-4133 Pratteln Fax +41 61 826 93 01<br>
Schweiz Web <a href="http://www.imp.ch" rel="noreferrer noreferrer" target="_blank">http://www.imp.ch</a><br>
______________________________________________________<br>
<br>
__________________________________________________________<br>
Kamailio - Users Mailing List - Non Commercial Discussions<br>
* <a href="mailto:sr-users@lists.kamailio.org" target="_blank" rel="noreferrer">sr-users@lists.kamailio.org</a><br>
Important: keep the mailing list in the recipients, do not reply only to the sender!<br>
Edit mailing list options or unsubscribe:<br>
* <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer noreferrer" target="_blank">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
</blockquote></div>