Home > Article > Backend Development > The latest version of PHP Fetion (PHPFetion v1.3)
Latest version (v1.3): http://code.google.com/p/php-fetion/downloads/detail?name=phpfetion_v1.3.0.zip (July 23, 2012: Fixed the problem of not being able to send messages to friends, adding the csrfToken field when sending messages to friends) For updates, please follow: http://blog.quanhz.com/ (1) Instructions for use1. There is only one file that needs to be included in your program: PHPFetion.php. Such as: <span style="color:#000088;">require</span><span> </span><span style="color:#008800;">'PHPFetion.php'</span><span style="color:#666600;">;</span> 2. Calling method such as: <span>$fetion </span><span style="color:#666600;">=</span><span> </span><span style="color:#000088;">new</span><span> </span><span style="color:#660066;">PHPFetion</span><span style="color:#666600;">(</span><span style="color:#008800;">'13500001111'</span><span style="color:#666600;">,</span><span> </span><span style="color:#008800;">'123123'</span><span style="color:#666600;">);</span><span> </span><span style="color:#880000;">// 手机号、飞信密码</span><span> $fetion</span><span style="color:#666600;">-></span><span>send</span><span style="color:#666600;">(</span><span style="color:#008800;">'13500001111'</span><span style="color:#666600;">,</span><span> </span><span style="color:#008800;">'Hello Fetion!'</span><span style="color:#666600;">);</span><span> </span><span style="color:#880000;">// 接收人手机号、飞信内容</span> 3. Others (1) Your program needs to be encoded in utf-8. (2) The send() method has a return value, and you can determine whether the sending is successful by analyzing the text. Considering that the wap interface will change, the judgment on the success of sending is not hard-coded in the class. (2) Implementation principle1. Use PHP to send HTTP requests to simulate logging into the WAP version of Fetion, and simulate sending Fetion. The implementation principle can be viewed at: http://blog.quanhz.com/archives/118 (3) Others1. wap Fetion login address: http://f.10086.cn 2. Author’s blog: http://blog.quanhz.com |