August 15, 200817 yr I currently use 360 works email plugin together with an Email to SMS service to send text messages from Filemaker to my customers . Lately there have been some reliability issues due to email servers blocking traffic. The company that does the email to sms conversion suggested I use an http post method to get the message from my database to their server, bypassing email completely. I noticed that Scriptmaster has been updated to handle http post , but I am completely out of my depth regarding this. Does anyone have any experience in using this plugin. I have some information from the company here: http://www.txtlocal.co.uk/sms-api.php . I am currently using a table called "outbox" that has fields called "message" , "to" and a script on FM9 Server running every 2 mins that finds any "pending" messages , sends them and sets a field to "sent". Any help would be apreciated
August 18, 200817 yr Author UPDATE: I downloaded a trial of 360 works Web Assistant plug-in and within 10 mins had successfully sent SMS messages from filemaker via http post commands.
August 21, 200817 yr Author yep , here it is: Set Error Capture [ On ] Go to Layout [ “SMS Centre Outbox” (SMS Centre Outbox) ] Enter Find Mode [ ] Set Field [ SMS Centre Outbox::Message_status; "Pending" ] Perform Find [ ] If [ Get ( LastError ) <> 0 ] Else Go to Record/Request/Page [ First ] Set Field [ SMS Centre Outbox::Message_status; "Sent" ] Set Variable [ $result; Value:WARegister ("regkey" ; "mycompanyname") ] Set Variable [ $result; Value:WASetInputValue( "uname" ; "myusername" ) & WASetInputValue( "pword" ; "mypassword") & WASetInputValue( "message" ; SMS Centre Outbox::Message) & WASetInputValue( "selectednums" ; SMS Centre Outbox: Recipient_formatted)& WASetInputValue( "from" ; "sender=mynumber") & WAGetURL( "https://www.txtlocal.com/sendsmspost. php") ] Loop Go to Record/Request/Page [ Next; Exit after last ] Set Variable [ $result; Value:WARegister ("regkey" ; "mycompanyname") ] Set Variable [ $result; Value:WASetInputValue( "uname" ; "myusername" ) & WASetInputValue( "pword" ; "mypassword") & WASetInputValue( "message" ; SMS Centre Outbox::Message) & WASetInputValue( "selectednums" ; SMS Centre Outbox:: Recipient_formatted)& WASetInputValue( "from" ; "sender=mynumber") & WAGetURL( "https://www.txtlocal. com/sendsmspost.php") ] Set Field [ SMS Centre Outbox::Message_status; "Sent" ] End Loop Set Variable [ $result; Value:WARegister ("regkey" ; "mycompanyname") ] Set Field [ SMS Centre Outbox::Remaining_sms_credit; Trim4(Let ( setup = WAReset & WASetInputValue( "uname" ; "txtlocalusername" ) & WASetInputValue( "pword" ; "mypassword" ) ; WAGetURL( "https://www.txtlocal.com/getcredits.php" ) )) ] End If I have this script triggered every minute from FM Server 9 and I have a table called SMS Outbox that holds the recipient, message and a pending/sent status. the last line of the script gets the remaining balance of credit from txtlocal and stores it in a global field. I hope it is of some use. Edited August 21, 200817 yr by Guest
August 21, 200817 yr ... weird, you've got some unnecessary stuff in there - a few minor changes Set Error Capture [ On ] Go to Layout [ “SMS Centre Outbox” (SMS Centre Outbox) ] Enter Find Mode [ ] Set Field [ SMS Centre Outbox::Message_status; "Pending" ] Perform Find [ ] If [ Get ( LastError ) = 0 ] Go to Record/Request/Page [ First ] Loop Set Variable [ $result; Value:WARegister ("regkey" ; "mycompanyname") ] Set Variable [ $result; Value:WASetInputValue( "uname" ; "myusername" ) & WASetInputValue( "pword" ; "mypassword") & WASetInputValue( "message" ; SMS Centre Outbox::Message) & WASetInputValue( "selectednums" ; SMS Centre Outbox: Recipient_formatted)& WASetInputValue( "from" ; "sender=mynumber") & WAGetURL( "https://www.txtlocal. com/sendsmspost.php") ] Set Field [ SMS Centre Outbox::Message_status; "Sent" ] Go to Record/Request/Page [ Next; Exit after last ] End Loop Set Variable [ $result; Value:WARegister ("regkey" ; "mycompanyname") ] Set Field [ SMS Centre Outbox::Remaining_sms_cre dit; Trim4(Let ( setup = WAReset & WASetInputValue( "uname" ; "txtlocalusername" ) & WASetInputValue( "pword" ; "mypassword" ) ; WAGetURL( "https://www.txtlocal.com/getcredits.php" ) )) ] End If
Create an account or sign in to comment