Try

exten => s,1,GotoIf($["${ARG1:0:5}"="220408"]?2:3)

This looks at the first 5 digits of ARG1. 

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ricardo
Carvalho
Sent: Tuesday, March 13, 2007 12:39 PM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: [asterisk-users] How to match wild card inside a GoToIf?

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

Any ideas?

Regards,
Ricardo.


_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to