YiiFramework extension that helps you send SMS messages using Skebby API with only one line of code. You need a Skebby subscription to send messages.
Tested on Yii 1.1.11, but should run on lower versions as well.
To send a message:
Yii::app()->skebbySms->send(array('to'=>'xxxxxx','message'=>'hello world'));
To retrieve the remaining credit:
Yii::app()->skebbySms->getCredit(YSkebbySms::CREDIT_TYPE_BASIC);
The first parameter is the return type, can be empty to return all your credits, or a specific type. The second can be the same config used for the send, except for the method which will be overwritten.
In configuration, add the following component:
'components' => array( ... 'skebbySms' => array( 'class'=>'ext.YSkebbySms.YSkebbySms', 'username'=>'your Skebby user', 'password'=>'your Skebby password', ), ... )
Send messages as follows:
$result = Yii::app()->skebbySms->send([per-sms configurations]); if ($result['result']) echo "Message sent"; else { echo "Message NOT sent: ".$result['message']; }
http://yiiframework.com
http://www.skebby.it/business/index/send-docs/
http://www.skebby.it/business/index/code-examples/
There's a lot of things to do, like implement sending to several recipients, scheduled send, and other advanced features of Skebby... See link above.
Be the first person to leave a comment
Please login to leave your comment.