注意:必须使用MSNP15协议,MSNP9用不成了。使用MSNP15时,应该先检查你的PHP是否开启了mhash、mcrypt、bcmath这三个模块

PHPChina讯:PHP MSN Class,支持MSNP9 (MSN 6.2)和最新的MSNP15 (WLM 8.1)协议(MSNP15协议支持离线消息),可以作为MSN机器人使用,或者给MSN、雅虎通发消息。

示例代码:

<?php 
 include_once(‘msn.class.php’); 
 $msn_username = “username@live.cn”;//消息发送人MSN帐号 
 $msn_password = “12345678″;//消息发送人MSN密码 
 $msn_list = array(“xxx@hotmail.com”,”xxx@live.cn”);//消息接收人MSN帐号 
 $msn = new MSN(‘MSNP15′);//采用MSNP15协议,支持离线消息 
 if ($msn->connect($msn_username, $msn_password)) { 
     $msn->sendMessage(“UTF-8编码的中文和英文”, $msn_list); 
 } 
?>

注意:使用MSNP15协议,PHP需要支持mhash;使用msnbot机器人功能,PHP需要支持pcntl。

开发语言: PHP
操作系统: 跨平台 
软件主页: http://code.google.com/p/phpmsnclass/  
下载地址: http://code.google.com/p/phpmsnclass/downloads/list  

http://www.phpchina.com/?action_zendinfoview_itemid_35813.html

Published in PHP
Tags:

3 Responses to “PHP MSN Class 最新版,支持MSN(注意:必须使用MSNP15协议)”

  1. 七月 31st, 2010 at 11:27 上午 #符号图案大全

    学习了,不错,做好一件事真的不容易

  2. 八月 4th, 2010 at 12:08 上午 #美女图片网

    好文章

  3. 八月 6th, 2010 at 1:29 上午 #问道推广员

    有意思。

Leave a Reply

请输入算式结果(看不清请点击图片)
(必须)