Home > php教程 > php手册 > 张进杰-PHP短信接口开发 成都短信接口 PHP案例

张进杰-PHP短信接口开发 成都短信接口 PHP案例

WBOY
Release: 2016-06-16 08:41:16
Original
1035 people have browsed it

PHP短信接口开发 成都短信接口 PHP案例。PHP短信接口开发 成都短信接口 PHP案例,联系专业工程师 QQ467477957
sms.php<?php <br /> if(!empty($_GET['sms'])){<br> $num = $_GET['num'];<br> $message = $_GET['message'];<br> set_phone($num,$message);<br> }<br> <br> function set_phone($num,$message){<br> //header("Content-type: text/html; charset=utf-8");<br> date_default_timezone_set('PRC'); //设置默认时区为北京时间<br> //短信接口用户名 $uid<br> $uid = '';<br> //短信接口密码 $passwd<br> $passwd = '';<br>         <br>         //$num ='136087976876';<br>         <br> $msg = rawurlencode(mb_convert_encoding($message, "gb2312", "utf-8"));<br> $gateway = "http://mb345.com:999/ws/Send.aspx?CorpID={$uid}&Pwd={$passwd}&Mobile={$num}&Content={$msg}&Cell=&SendTime=";<br> <br> $result = file_get_contents($gateway);<br>  <br> if(  $result >= 0 )<br> {<br>                 echo $gateway;<br>                 echo $result;<br> echo "发送成功! 发送时间".date("Y-m-d H:i:s");<br> }<br> else<br> {<br> echo "发送失败, 错误提示代码: ".$result;<br> }<br> exit;<br> }<br> ?><br> <br> <meta> <br> <br> <br> <br> <center> <br> <form>手机号码:<br> <input><br> <br>短信内容:<br> <input><br><br> <input><br><br> <br> <br> </form> <br> </center> <br> <br> 张进杰-PHP短信接口开发 成都短信接口 PHP案例
张进杰-PHP短信接口开发 成都短信接口 PHP案例
张进杰-PHP短信接口开发 成都短信接口 PHP案例

AD:真正免费,域名+虚机+企业邮箱=0元

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template