- hechzerimAsked on August 19, 2014 at 06:21 AM
I've been searching all around the forum for a solution but could'nt find one.
I am trying to send a submission automatic text messege to the form filler's mobile.
I am registered with an API SMS service and I want to send an automatic messege to who ever fills out the form with his name in the text body and so that the phone number he entered will be the reciever number.
the API service provider sent me a .php file for example.
I've attached the .php example file.
your help would be much appreciate!
- JotForm Supportashwin_dAnswered on August 19, 2014 at 09:42 AM
There are multiple ways to achieve your requirement:
1. You can set up Webhook to send HTTP POST notification where you can use your own API code to sens SMS notification using your API code. The following guide should help you: http://www.jotform.com/help/245-How-to-Setup-Webhook-with-JotForm
2. You can take advantage of our custom thank you URL to redirect your user to your own PHP page. In this custom PHP page you can use read your form's POST data and use your SMS service provider's API to send SMS. The following guide should help you: http://www.jotform.com/help/213-Send-POST-Data-From-JotForm-Using-PHP-in-Custom-Thank-You-Page
Hope this helps.
Do get back to us if you have any questions.
- HechzerimAnswered on August 19, 2014 at 11:38 AM
Thank you for your reply. I hsve tried that already and no success. I have uploaded the php file that the api service provider gave me and its integrated to my form using webhook but it wont send any sms to the submiter. If you could help me and fix the php file to work it would me great. Thank you very much.
- JotForm Supportashwin_dAnswered on August 19, 2014 at 12:56 PM
Though I am not a PHP expert but I will give it a try. I will also forward this thread to my colleague as well who is a PHP expert.
We will get back to you as soon as we have any update on this.
- hechzerimAnswered on August 20, 2014 at 12:23 AM
Thank you very much. waiting for your reply.
- JotForm Supportashwin_dAnswered on August 20, 2014 at 02:19 AM
I haven't started work on it. I will check the API code and get back to you if I have any questions.
- hechzerimAnswered on August 21, 2014 at 08:28 PM
- JotForm Support ManagerJeanetteAnswered on August 21, 2014 at 11:43 PM
I'll forward your request to Ashwin so he can update you.
- hechzerimAnswered on August 24, 2014 at 06:30 PM
- JotForm SupportjonathanAnswered on August 24, 2014 at 08:07 PM
Can you share to us the URL where you have tried this already?
We will check also what have you created so far.
- JotForm SupportjonathanAnswered on August 24, 2014 at 08:12 PM
I am sorry, I did not realized you had already provided the URL. This onehttp://hechzerim.co.il/%D7%91%D7%95%D7%90%D7%95-%D7%A0%D7%AA%D7%97%D7%99%D7%9C/
But can you share to us the PHP code of thesendsms page (sendsms.php) in your website where you use the Webhooks to trigger the URL of the sms script.
- hechzerimAnswered on August 25, 2014 at 04:20 AM
This is what I tried to do:
- JotForm SupportWelvinAnswered on August 25, 2014 at 06:44 AM
Thank you for providing the codes. We'll check this get back to you.
- hechzerimAnswered on August 25, 2014 at 02:43 PM
Waiting for your reply
- hechzerimAnswered on August 30, 2014 at 02:31 PM
- JotForm SupportEltonCrisAnswered on August 31, 2014 at 12:07 AM
Our sincere apologies for the delay.
Please try this PHP script: http://pastiebin.com/54029a7e5ca31. You have to edit the required API details provided by your SMS provider found on this script. After that, save it as a php file, upload it to your server and add it to your form as webhook URL.
Note that this code is untested, simply because we do not have the facility to do so and it is not supported with our country. Therefore we cannot guarantee you of any assurance if it is working or not unless you keep trying and report to us the status of this so we can assist you further with this.
Furthermore, I have been trying to find the SMS API documentation page you're using so at least we could check and verify the parameters you used in your sample code. Some parameters really confused me specially the Jotform Authentication Key (authkey) which I've found on your sample code. If you know the documentation page, please let us know. That will tell us the correct parameters to include on the post.
We will wait your test result using this script.
- hechzerimAnswered on August 31, 2014 at 04:16 AM
Thank you for your hard work.
unfortunately the script you gave me didnt work.
I will post a link to the documentation file:
Maybe this can help.
- JotForm SupportjonathanAnswered on August 31, 2014 at 05:29 AM
Thank you for the documentation file.
My colleague have received your message update also. We need time to check this further.
We will update you here for any status update as soon as we can.
- JotForm SupportEltonCrisAnswered on August 31, 2014 at 07:11 AM
Try this: http://pastiebin.com/54029a7e5ca31. I have updated all the variables according to the documentation.
Again, replace the API Username and Password found on this script and add it as a Webhook URL to your form.
I hope this works this time. If not, I think it is best to get in contact with your SMS API provider and let them check the php code. This is the best way to get this rectified. I'm sure they will be able to assist you further with this. The php code is written correctly but we just cannot test it here because like I've said earlier the SMS service isn't supported in our country.
- JotForm SupportEltonCrisAnswered on August 31, 2014 at 07:23 AM
Sorry, just updated the username and password variable to "un" and "pw". If you have copied the code after my reply just now, kindly copy it again. Thanks!
- JotForm SupportsethAnswered on February 06, 2017 at 04:01 AM
This is an old thread, so I transferred your question to a new one. Please follow up there: