PHP code example of evan-li / think-sms

1. Go to this page and download the library: Download evan-li/think-sms library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

evan-li / think-sms example snippets


return [
    // 驱动类型, 支持 zsd(众视达) aliyun(阿里云,待支持) ucpaas(云之讯,待支持)
    'driver' => 'zsd',

    // 众视达参数配置
    'zsd' => [
        // 行业短信参数配置
        'biz' => [
            'account' => 'account',
            'password' => 'password',
            'extno' => 'extno'
        ],
        // 营销短信参数配置
        'marketing' => [
            'account' => '',
            'password' => '',
            'extno' => ''
        ],
        // 灰度营销短信参数配置
        'gray_marketing' => [
            'account' => '',
            'password' => '',
            'extno' => ''
        ],
    ]
];

Sender::sendVerifyCodeSms('手机号', '短信内容', '短信签名');