[Asterisk-Users] gotoif regex?
John Hill
jhill at noach.com
Thu Oct 21 08:18:31 MST 2004
I have a test for all tool free numbers.
This works but would using regex in one statement be more efficient?
exten => s,4,GotoIf($["${CALLERIDNUM:0:3}" = "888"]?s|108)
exten => s,5,GotoIf($["${CALLERIDNUM:0:3}" = "877"]?s|108)
exten => s,6,GotoIf($["${CALLERIDNUM:0:3}" = "866"]?s|108)
exten => s,7,GotoIf($["${CALLERIDNUM:0:3}" = "800"]?s|108)
Would this be the proper syntax?
exten => s,4,GotoIf($[${CALLERIDNUM:0:3} : 888|877|866|800]?s|108)
I tried this but I'm not sure it works.
Thanks
--John
More information about the asterisk-users
mailing list