$CurrentCalling=sprintf("%s %s",$RowData,$RowData) įprintf($FP,"Channel: SIP/% \n" ,$RowData) įprintf($FP,"Setvar: FirstName=%s\n",$RowData) įprintf($FP,"Setvar: RecId=%d\n",$RowData) $FileOut=sprintf("/var/spool/asterisk/outgoing/%s_%s",$RowData,$RowData) $FileName=sprintf("/tmp/ToCall/%s_%s",$RowData,$RowData) While ($RowData=mysql_fetch_assoc($Result)) $SqlCmd="SELECT Id,FirstName,LastName,PhoneNumber from Members where CallReminder='Y' order by LastName asc" Printf("Today is %s, which is not the second Tuesday of the month\n",$Today) $SecondTues = strftime("%d",strtotime("second tuesday of $MonthYear")) only run on the 2nd Tuesday of the monthĭate_default_timezone_set("America/New_York") The “program” that runs every Tuesday: 2)ĮrrPrint("Creating Database Connection") ĮrrPrint("Destroying Database Connection") exten => s,1,MYSQL(Connect connid localhost dbuser dbpassword DATABASE) exten => s,n,GotoIf($["$) exten => 2,n,Goto(s,Done) exten => 3,1,Swift("Great! See you there.") exten => 3,n,Goto(s,Done) exten => error,1,NoOp(Connection error - Ack!) exten => error,2,Hangup I know that I should make a change to allow for a gosub for the main “text” of the message, since the HUMAN-ANSWERED and MACHINE-ANSWERED message is 99% the same, the only difference is that the MACHINE-ANSWERED message skips the menu options. So what if it it takes hour or so to call the members. I could not see spending $129 to license 2 outbound calls to be active at one time. This is due to the licensing of the voice font (Cepstral) that I use. Added code to check that only 1 outbound call was active at any one time. The program is called by a crontab entry, but only does it’s thing second tuesday of the month at 12:00 noon. Finally, wrote a quick php program to create call files and to feed them to asterisk via /var/spool/asterisk/outgoing. Added menu to allow user to replay message, opt-out of receiving future messages and allow user to said (by pressing 3) they might attend the meeting. Next, threw together am outbound dial plan, to check for human or machine answered calls, update the database with the call’s outcome. Solution: Use asterisk to out dial to the members and play a recorded messages.ĭamn, I love technology! Created a mysql database of all the members, containing first/last name, phone number, status, last time called and an opt-out flag. Problem 2: It was the secretary’s responsiblity to do the calling… Problem 1: Lack of attendance at our homeowners meetings due to no one remembering when the meeting is…
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
March 2023
Categories |