承接 netjoint/laravel-sms 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

netjoint/laravel-sms

Composer 安装命令:

composer require netjoint/laravel-sms

包简介

SMS Component for Laravel 5 - 第三方短信平台客户端

README 文档

README

Supported SMS Providers

Installation

Add laravel-sms to your composer.json file

"require": {
  "netjoint/laravel-sms": "dev-master"
}

Registering the Package

For Laravel 5.1

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,
)

For Laravel 5.0

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',
)

Configuration

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

Usage

use NetJoint\LaravelSms\Facades\Sms;

// $mobile  mobile number
// $message SMS message
// return True if success and False if fail
Sms::send($mobile, $message);

Make a Contribution

Place your implementation of ProviderInterface in Provider under the namespace NetJoint\LaravelSms\Provider and then send me pull request.

Licence

MIT

统计信息

  • 总下载量: 26
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-09-12