`
lukeshei
  • 浏览: 389451 次
  • 性别: Icon_minigender_1
  • 来自: 台北
社区版块
存档分类
最新评论

3分鐘學會使用程式發送msn訊息,php篇(一) (MSN機器人)

阅读更多
<div?class="post?hentry"><a?name="8471015093699403964"><h3?class="post-title?entry-title"><a?href="http: rd-program.blogspot.com="" 2008="" 11="" 5msnphp.html"="">3分鐘學會使用程式發送msn訊息,php篇(一)<div?class="post-header-line-1"> <div?class="post-body?entry-content">

<a?href="http: www.program.com.tw="" newpage="" msnsdk.htm"=""><font?color="#6699cc">msnSDK訊息控制開發套件?同時支援MSN/Yahoo即時通?訊息雙向傳遞<br?><br?>ps.也請參考?<a?href="http: rd-program.blogspot.com="" 2008="" 11="" msnsdk.html"=""><font?color="#666699">msnSDK的使用流程?<br?>================================<br?><br?>步驟一:取得api?使用的權限(GETSPID)<br?><br?><!---->$file="http://59.120.234.84:8082/msnSDK/msn_cgi-win32?FUNC=GETSPID&USERID=apiblogt1&PASSWD=msnsdkt"?;<br?>$myArray='';<br?>$mySession='';<br?>$myResult='';<br?>$getline='';<br?><br?>if?(!($fp?=?fopen($file,?"r")))?{<br?>die("could?not?open?XML?input");<br?>}<br?>while?($getline?=?fgets($fp,?4096))?{<br?>$myArray=explode("\t",$getline);<br?>$myResult=$myArray[0];<br?>$mySession=?$myArray[1];<br?>}<br?>fclose($fp);<br?>if?($myResult=="0")<br?>{<br?>echo?"get?session?fail...?<br?>";<br?>exit();<br?>}<br?>else<br?>{<br?>//$_SESSION["mySession"]=?$mySession;<br?>echo?"get?session=".$mySession."<br?>";<br?>}<br?>echo?"<a?href='REGISTER.php?uids=".$_GET["uids"]."&session=".$mySession."'>go?register?page</a>";<br?>?><br?><br?>步驟二:?邀請聯絡人(REGISTER)<br?><br?><!---->$myArray='';<br?>$mySession='';<br?>$myResult='';<br?>$getline='';<br?>//register:<br?>$file="http://59.120.234.84:8082/msnSDK/msn_cgi-win32?FUNC=REGISTER&uids=".$_GET["uids"]."&session=".$_GET["session"]?;<br?>echo?$file."<br?>";<br?><br?>if?(!($fp?=?fopen($file,?"r")))?{<br?>die("could?not?open?XML?input");<br?>}<br?>while?($getline?=?fgets($fp,?4096))?{<br?>$myArray=explode("\t",$getline);<br?>$myResult=$myArray[0];<br?>}<br?>fclose($fp);<br?><br?>if?($myResult=="0")<br?>{<br?>echo?"register?fail...?".$myArray[1]."<br?>";<br?>//exit();<br?>}<br?>else<br?>{<br?>echo?"register?ok.?account=".$myArray[2]."<br?>";<br?>}<br?>echo?"<a?href='SENDMSG.php?uids=".$_GET["uids"]."&msg=hello&encoding=utf-8&flags=0&session=".$_GET["session"]."'>go?SENDMSG?page</a>";<br?>?><br?><br?>步驟三:發送訊息(SENDMSG)<br?><br?><!---->$myArray='';<br?>$mySession='';<br?>$myResult='';<br?>$getline='';<br?><br?>//send?message:<br?>$file="http://59.120.234.84:8082/msnSDK/msn_cgi-win32?FUNC=SENDMSG&uids=".$_GET["uids"]."&msg=".$_GET["msg"]."&encoding=utf-8&flags=0&session=".$_GET["session"]?;<br?>if?(!($fp?=?fopen($file,?"r")))?{<br?>die("could?not?open?XML?input");<br?>}<br?>while?($getline?=?fgets($fp,?4096))?{<br?>$myArray=explode("\t",$getline);<br?>$myResult=$myArray[0];<br?>}<br?>fclose($fp);<br?>if?($myResult=="0")<br?>{<br?>echo?"send?message?fail...?".$myArray[1]."<br?>";<br?>exit();<br?>}<br?>else<br?>{<br?>echo?"send?message?ok.?message=".$myArray[2]."<br?>";<br?>}<br?>?><br?><br?>其他更詳細的參數可以參考<a?href="http: tcmail.program.com.tw="" image="" msnsdk.pdf"=""><font?color="#666699">msnSDK訊息控制開發套件程式介面說明書

<div?style="clear:?both"> <div?class="post-footer"><p?class="post-footer-line?post-footer-line-1"><span?class="post-labels">標籤:?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" 3%e5%88%86%e9%90%98%e5%ad%b8%e6%9c%83%e4%bd%bf%e7%94%a8%e7%a8%8b%e5%bc%8f%e7%99%bc%e9%80%81msn%e8%a8%8a%e6%81%af"=""><font?color="#666699">3分鐘學會使用程式發送msn訊息,?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" msn"=""><font?color="#6699cc">msn,?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" msnlib"=""><font?color="#6699cc">msnlib,?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" msnsdk"=""><font?color="#6699cc">msnSDK,?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" phpmsn"=""><font?color="#6699cc">phpmsn,?<a?rel="tag"?href="http: rd-program.blogspot.com="" search="" label="" yahoo%e5%8d%b3%e6%99%82%e9%80%9a"=""><font?color="#6699cc">yahoo即時通

<p?class="post-footer-line?post-footer-line-2"> 

<p?class="post-footer-line?post-footer-line-3"> 

<textarea?class="php"?name="code">請在此填寫程式碼

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics