PHP群发营销短信DEMO示例代码

// 接口类型:互亿无线营销短信批量发送DEMO
// 账户注册:请通过该地址开通账户 http://user.ihuyi.com/
//发送短信测试

//打开php.ini文件中的 always_populate_raw_post_data = -1;
header("Content-type:text/html; charset=UTF-8");

require 'ihuyi/sms.class.php';
$config = require 'ihuyi/config.php';

$sms = new sms($config);

$mobile = array('135xxxxxxxx','135xxxxxxxx');
$content = '您好,短信内容,回T退订';
$product_id = 1001;
$sign_name = '互亿无线';

//发送短信
$res = $sms->send($mobile, $content, $product_id, $sign_name);
$sms->log('send', $res);
print_r($res);