进入后台-基本资料-通信设置,将代码改成如下所示,然后填入短信框里
(注意:有些没有在后台直接添加,需要将函数保存为php文件,保存到config/mobphp/mysendsms.php)
GBK版本|
1
2
3
4
5
6
7
8
9
10
11
|
function yjsendsms($m1,$m2){ $user = '您的短信宝账户'; $password = '您的短信宝密码'; $sign = "【站长交易网】";//短信签名 if(!empty($m1)){ $url .= '?u='.$user.'&p='.md5($password).'&m='.$m1.'&c='.urlencode(iconv("GBK","UTF-8//IGNORE",$sign.$m2)); $ret = file_get_contents($url); }} |
|
1
2
3
4
5
6
7
8
9
10
|
function yjsendsms($m1,$m2){ $user = '您的短信宝账户'; $password = '您的短信宝密码'; $sign = "【站长交易网】";//短信签名 if(!empty($m1)){ $url .= '?u='.$user.'&p='.md5($password).'&m='.$m1.'&c='.urlencode($sign.$m2); $ret = file_get_contents($url); }} |

