Content on this page requires a newer version of Adobe Flash Player.

Get Adobe Flash player

bulk sms prices pricingBulk SMS Software

PHP and SMS

Posted on November 25th, 2009 by Nick.
Categories: All SMS Gateway Documentation, Technical

PHP is the very popular web scripting language, to make things easy for the PHP programmer we have provided some (almost!) plug and play  PHP code that easily integrates PHP with our SMS Gateway.

Simple Example of sending SMS with PHP

This class allows you to send SMS using PHP,  please feel free to modify at will. You just need the username and password from your account login as the constructor arguments. Download PHP 5 SMS API Class

Example:

$sms = new SendSMSXML("myUsername","myPassword");
/// send function args: mobile number, your message, the originator (sender id)
$sms->send("4477777777","my message","me");

As you can see there is nothing to it!

Take a look at the  more involved document describing how you can integrate PHP with the SMS short code service. This example uses a game where by you text in the number of sweets you think is in a jar. You then receive a response depending on how close you were.

  • Share/Bookmark