| Package Data | |
|---|---|
| Maintainer Username: | yanzhou |
| Maintainer Contact: | netjoint@163.com (NetJoint Ltd) |
| Package Create Date: | 2015-09-11 |
| Package Last Update: | 2015-09-14 |
| Language: | PHP |
| License: | MIT |
| Last Refreshed: | 2025-12-14 03:04:27 |
| Package Statistics | |
|---|---|
| Total Downloads: | 26 |
| Monthly Downloads: | 0 |
| Daily Downloads: | 0 |
| Total Stars: | 0 |
| Total Watchers: | 2 |
| Total Forks: | 0 |
| Total Open Issues: | 0 |
Add laravel-sms to your composer.json file
"require": {
"netjoint/laravel-sms": "dev-master"
}
Register the service provider within the providers array found in config/app.php
'providers' => array(
// ...
NetJoint\LaravelSms\LaravelSmsServiceProvider::class,
)
Add an alias within the aliases array found in config/app.php:
'aliases' => array(
// ...
'Sms' => NetJoint\LaravelSms\Facades\Sms::class,
)
Register the service provider within the providers array found in config/app.php
'providers' => array(
// ...
'NetJoint\LaravelSms\LaravelSmsServiceProvider',
)
Add an alias within the aliases array found in config/app.php:
'aliases' => array(
// ...
'Sms' => 'NetJoint\LaravelSms\Facades\Sms',
)
Publish the package's config file to config/laravel-sms.php
php artisan vendor:publish --provider="NetJoint\LaravelSms\LaravelSmsServiceProvider"
Add the following to your .env file
# Default SMS Provider(lowercase)
SMS_PROVIDER=yimei
# Serial key for SMS Provider Yimei
SMS_YIMEI_CDKEY=2SDK-EMY-6688-AAAAA
# Password for SMS Provider Yimei
SMS_YIMEI_PASSWORD=123456
use NetJoint\LaravelSms\Facades\Sms;
// $mobile mobile number
// $message SMS message
// return True if success and False if fail
Sms::send($mobile, $message);
Place your implementation of ProviderInterface in Provider under the namespace NetJoint\LaravelSms\Provider and then send me pull request.
MIT