• Resolved otti.steinhauer

    (@ottisteinhauer)


    Hello,
    at my plugin I’m already sending automatic mails with wp_mail() function. Now I want to send SMS and I don’t know how to do that.
    I have got via a form the number of a mobile phone and I can create the message via code. So what is the best way to send the message as SMS to the number?

    Thanks

    Ottilie

Viewing 4 replies - 1 through 4 (of 4 total)
  • There are many SMS plugins for WordPress such as WordPress SMS ( https://wordpress.org/plugins/wp-sms/ ) that can do this for you. There are some paid services like Twilio that have a WordPress plugin and provide a paid service where you pay per SMS message sent.

    Another option would be to write your own code and many providers of text messaging services will provide you with php code to do this if you are a registered client with their service.

    A lot will depend on the service you use and how open your phone service provider is to allowing you to do this.

    Bob

    Thread Starter otti.steinhauer

    (@ottisteinhauer)

    Hello Bob,
    thank You for your help on my problem. I hav got some more questions. The plugin you suggested is very interesting At teh description are four steps to send sms:

    global $sms;
        $sms->to = array('09000000000');
        $sms->msg = "Hello World!";
        $sms->SendSMS();

    Is it possible to put this code into my plugin-code and send the sms from my own function?

    Thanks again for help and please excuse my bad English, I hope I could explain what I meant.

    Ottilie

    Moderator bcworkz

    (@bcworkz)

    Hello Ottilie,

    That plugin, and all plugins (and other code) available through wordpress.org are all GPL licensed. You are free to copy and distribute such code in your own work provided you distribute your work under the same GPL terms.

    You should properly annotate and attribute any code you copy so the original author receives proper credit for their work.

    Thread Starter otti.steinhauer

    (@ottisteinhauer)

    Hello Bob, hello bcworkz,

    thanks for your reply. I have not tested this plugin yet, but I think I will find a way to solve my problem with yout information.

    Ottilie

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to send a SMS’ is closed to new replies.