91成人在线播放_欧美一区二区视频在线观看_91精品国产高清久久久久久_国产精品久久亚洲不卡4k岛国


待發(fā)短信

在線客服
產(chǎn)品支持 短信寶客服
合作渠道 渠道合作
服務(wù)咨詢

4001-021-502

工作時(shí)間

9:00-21:00

DESTOON_V8.0新增短信寶短信接口

DESTOON是一款B2B網(wǎng)站管理系統(tǒng)他是基于PHP+MYSQL,二次開發(fā)及后期維護(hù)方便,小編對(duì)這款系統(tǒng)還比較了解,今天就以替換短信接口為例為大家講解一下如何進(jìn)行二次開發(fā),我們今天講解的是8.0版本,使用的短信接口是我們短信寶短信群發(fā)平頭的短信接口,我們短信寶短信群發(fā)平臺(tái)非常穩(wěn)定,發(fā)送速度快,注冊(cè)就送測(cè)試短信,推薦大家使用。

1:打開項(xiàng)目:\admin\template\setting.tpl.php 新增短信寶接口

?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<div id="Tabs7" style="display:none">
<table cellspacing="0" class="tb">
<tr>
<td class="tl">短信寶用戶名</td>
<td><input name="config[cloud_uid]" type="text" id="cloud_uid" value="<?php echo $cloud_uid;?>" size="30"/>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.gjrencai.com" target="_blank" class="t">[沒有賬號(hào)點(diǎn)此申請(qǐng)帳號(hào)]</a></td> 
</tr>
<tr>
<td class="tl">短信寶密碼</td>
<td><input name="config[cloud_key]" type="text" id="cloud_key" value="<?php echo $cloud_key;?>" size="30" onfocus="if(this.value.indexOf('**')!=-1)this.value='';"/></td>
</tr>
<tr>
<td class="tl">提示信息</td>
<td class="f_red">以下云服務(wù)需要先填寫正確的帳號(hào)和密鑰方可開啟成功</td>
</tr>
<tr>
<td class="tl">手機(jī)短信</td>
<td>
<input type="radio" name="setting[sms]" value="1"  <?php if($sms){ ?>checked <?php } ?> onclick="Ds('dsms');"/> 開啟&nbsp;&nbsp;&nbsp;&nbsp;
<input type="radio" name="setting[sms]" value="0"  <?php if(!$sms){ ?>checked <?php } ?> onclick="Dh('dsms');"/> 關(guān)閉&nbsp;&nbsp;&nbsp;&nbsp;
<a href="javascript:Dwidget('?moduleid=2&file=sendsms&action=record', '短信記錄');" class="t">[查看記錄]</a>
</td>
</tr>

打開項(xiàng)目\include\global.func.php 文件,修改send_sms方法

?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
function send_sms($mobile, $message, $word = 0, $time = 0) {
        global $db, $DT, $DT_TIME, $DT_IP, $_username;
        if(!$DT['sms'] || !DT_CLOUD_UID || !DT_CLOUD_KEY || !is_mobile($mobile) || strlen($message) < 5) return false;
        $word or $word = word_count($message);
        $sms_message = convert($message, DT_CHARSET, 'UTF-8');
        $data = 'u='.DT_CLOUD_UID.'&p='.md5(DT_CLOUD_KEY).'&m='.$mobile.'&c='.rawurlencode($sms_message);
        $code = dcurl('http://api.smsbao.com/sms', $data);
        if($code == 0) {
                $code = true;
        else {
                $code = 'Can Not Connect SMS Server';
        }
        $db->query("INSERT INTO {$db->pre}sms (mobile,message,word,editor,sendtime,code) VALUES ('$mobile','$message','$word','$_username','$DT_TIME','$code')");
        return $code;
}

好了經(jīng)過以上的添加,短信寶DESTOON_v8.0系統(tǒng)增加手機(jī)驗(yàn)證就已經(jīng)安裝成功,可以正常使用了

報(bào)備一下短信寶的VIP模板,這樣就可以走短信寶的優(yōu)質(zhì)通道了,即便遇到敏感文字我們都不會(huì)人工審核,短信內(nèi)容3~5秒就可送達(dá)。

另外:我們已經(jīng)開發(fā)好完整的DESTOON_v8.0系統(tǒng)短信寶插件,點(diǎn)擊此鏈接 下載及查看安裝流程。

開源插件

最新更新

電商類

CMS類

微信類

文章標(biāo)簽