kriss/yii2-bd-sms

Yii2 必答短信的组件

Installs: 100

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 3

Forks: 0

Open Issues: 0

Type:yii2-extension

v1.0 2018-01-23 08:51 UTC

This package is auto-updated.

Last update: 2024-10-10 14:24:09 UTC


README

Yii2 必答短信的组件,仅适用于必答短信

Installation

php composer.phar require --prefer-dist kriss/yii2-bd-sms -vvv

Usage

  1. 定义一个 SmsSender 继承 AbstractSmsSender

see SmsSender.php

  1. 配置 config
use kriss\bd\sms\Sms;

$config = [
    'components' => [
        Sms::COMPONENT_NAME => [
            'class' => Sms::className(),
            'enable' => true,
            'account' => 'xxxx',
            'password' => 'xxxxx',
            'logCategory' => 'bd-sms',
        ]
    ]
]
  1. Controller

see AppController.php