[asterisk-users] Re: asterisk-users Digest, Vol 32, Issue 48
David Cook
dbc_asterisk at advan.ca
Tue Mar 13 12:39:53 MST 2007
> From: Ricardo Carvalho <rjcarvalho at reit.up.pt>
> Subject: [asterisk-users] How to match wild card inside a GoToIf?
> To: Asterisk Users Mailing List - Non-Commercial Discussion
> <asterisk-users at lists.digium.com>
>
> How can I match wildcards inside a GoToIf?
>
> I have something like this, but it doesn't work:
>
> [default]
> exten => _2XXXXXXXX,1,Macro(outcall,${EXTEN})
> [macro-outcall]
> exten => s,1,GotoIf($["${ARG1}" = "220408XXX"]?2:3)
> exten => s,2,Hangup
>
You are going to need a substring of the original. I'm thinking
something like the following although I haven't tested it.
exten => s,1,GotoIf($["${ARG1:3}" = "220408"]?2:3)
dbc.
More information about the asterisk-users
mailing list