Hello
I cant seem to escape the + symbol on a regex:
same => n,Set(CALLERID(num)=+337123456789)
same => n,Set(CALLERID(num)=${IF($[${REGEX("^\+33[67].+" ${CALLERID(num)})} = 1]?0${CALLERID(num):3}:${CALLERID(num)})})
[Jan 6 15:40:33] WARNING[15282][C-0000003b]: func_strings.c:977 regex: Malformed input REGEX(): Invalid preceding regular expression
[Jan 6 15:40:33] WARNING[15282][C-0000003b]: ast_expr2.fl:470 ast_yyerror: ast_yyerror(): syntax error: syntax error, unexpected ‘=’, expecting $end; Input:
= 1
If I replace the \+ with . (dot), it works - I fail to understand how to escape the + sign, to match E164 numbers.
Any help would be appreciated !
J.
ps: Happy New Year to all of you !