if ($dzzt==1){
$dxa= $dsql->GetOne("SELECT userid from hw_shops_orders where oid='$n' ");
$mid=$dxa[userid];
$dx= $dsql->GetOne("SELECT mobile from hw_member where mid='$mid' ");
$mobile = $dx[mobile]; //号码,多个号码用逗号隔开/
if(preg_match("/1[3458]{1}/d{9}$/",$mobile)){//正则判断手机号是否正确
$ok="ok";
}else{
$ok="no";
}
if(!empty($mobile)){
$bs=3;
$dx= $dsql->GetOne("SELECT nr from hmdxnr where fl='$bs' ");
$oid=$n;
$zhifue=$zhifue;
$yue=$yue;
$zwnr=str_replace('#kid#',$userid,"$dx[nr]");
$zwnr=str_replace('#ddid#',$oid,$zwnr);
$zwnr=str_replace('#zfje#',$zhifue,$zwnr);
$zwnr=str_replace('#zhye#',$yue,$zwnr);
$content =urlencode($zwnr); //内容
$time=''; //发送时间
$mid=''; //可选项,根据用户账号是否支持扩展
//即时发送
$cgid="912";
$url='http://smsapi.c123.cn/OpenPlatform/OpenApi?action=sendOnce&ac=接口商账号&authkey=短信接口商提供key&cgid='.$cgid.'&c='.$content.'&m='.$mobile;
$html=file_get_contents($url);
$ztm=",成功发送到手机";
}else{
$ztm=",手机不正确,请先设置手机";
}
}
此文由 网站目录_网站网址收录与提交入口 编辑,未经允许不得转载!: