@Sc00by wrote:
Hi all
I currently have a need for our system to send an email when particular numbers are dialled.
I am trying to get the below code to work but can't get it to match. I need to match if someone dials 999, 9999, 911, 9911, 112 or 9112
Can anyone advise on what I have to change for it to check the above numbers?
[macro-dialout-predial-hook]
exten => s,1,GotoIf($["${OUTNUM}" = "999"]?email:noemail)
exten => s,n(email),System(echo "Message body!" | mail -s "Message subject" FN-GM@wherever.com)
exten => s,n(noemail),MacroExit()Thanks
Posts: 4
Participants: 2