[asterisk-users] Check if a variable is set
Danny Nicholas
danny at debsinc.com
Fri Oct 16 09:16:05 CDT 2009
Why not this?
[macro-extcall]
;Macro created by Ish to handle external national calls
exten => s,1,Set(CALLERID(all)=${ARG2})
exten => s,n,Gotoif($["${ARG3}" != "1"]?dialit)
exten => s,n,ExecIf(${ARG3}=1|Monitor|My monitor arguments)
exten => s,n(dialit),Dial(SIP/44${ARG1}@carrier,45)
exten => s,n,Hangup
-----Original Message-----
From: asterisk-users-bounces at lists.digium.com
[mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Ishfaq Malik
Sent: Friday, October 16, 2009 9:08 AM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Check if a variable is set
Hi
Here it is
[macro-extcall]
;Macro created by Ish to handle external national calls
exten => s,1,Set(CALLERID(all)=${ARG2})
exten => s,2,ExecIf(${ARG3}=1|Monitor|My monitor arguments)
exten => s,3,Dial(SIP/44${ARG1}@carrier,45)
exten => s,4,Hangup
Execution id Macro(extcall|Dialled Number|Caller CLI)
Now to enable monitoring for an outgoing line it would be
Macro(extcall|Dialled Number|Caller CLI|1)
But I have 79 of these in the system already with just the 2 arguments and
we use realtime so they are all in a DB rather than text file so I'd rather
not go through all the existing ones and change them to
Macro(extcall|Dialled Number|Caller CLI|0)
If I don't have to.
Also, I don't like getting bested by machines!
Ish
More information about the asterisk-users
mailing list