Sending SMS via Aruba api ¶
Sending SMS via Aruba SMS.
Installation ¶
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist yetopen/yii2-sms-aruba "@dev"
or add
"yetopen/yii2-sms-aruba": "@dev"
to the require section of your composer.json
file.
Configuration ¶
In the application configuration, components
section, add the following:
'smsaruba' => [
'class' => yetopen\smsaruba\SmsAruba::class,
'username' => 'MyUsername', // ArubaSMS username (Smsxxx)
'password' => 'MyPassword', // ArubaSMS password ()
'senderName' => 'Sender', // The default sender name
],
Usage ¶
You can send SMS by calling send
:
Yii::$app->smsaruba->send(
['+393344556677'], // Enter the number(s) you want to send the message to; (the prefix is not necessary)
'Hi, this is a test!' // The message to send
);
If you have any questions, please ask in the forum instead.
Signup or Login in order to comment.