本帖最后由 republican 于 2010-10-5 11:38 编辑
本论坛的后台获取方法,刚花了一小时研究,顺带更新了自己的UDF。
我只测试了自己的用户ID,其他人未测.
需要用到的UDF: http://www.autoitx.com/thread-18528-1-1.html
#Include <ACN_HASH.au3>
#include <Array.au3>
#include <WinHttp_GetRespond.au3>
$MyOpen=_WinHttpOpen()
Local $Request[1]=["$hRequest"]
$rContext=_WinHTTP_GetRespond($MyOpen,"http://www.autoitx.com/forum-6-1.html")
$xzr_sid=StringRegExpReplace($rContext[3],"(xzr_sid.*?;).*","$1")
$Name=InputBox("请输入用户名","你知道的")
$PassWord=InputBox("请输入密码","你知道的")
$PassWord=StringLower(StringTrimLeft(_MD5($PassWord),2))
$rContext=_WinHTTP_GetRespond($MyOpen,"http://www.autoitx.com/logging.php?action=login&loginsubmit=yes",1 ,-2,0,0,"formhash=b692c94e&loginfield=username&username="&$Name&"&password="&$PassWord&"&questionid=0&answer=&loginsubmit=%B5%C7%C2%BC",$xzr_sid,"Content-Type: application/x-www-form-urlencoded","_DownLoadByResPodn",$Request)
$rContext=_WinHTTP_GetRespond($MyOpen,"http://www.autoitx.com/forum-6-1.html",0,2,0,0,"",$xzr_sid& " " &$rContext)
MsgBox(0,"",StringTrimLeft(BinaryToString($rContext[0]),1000))
FileWrite(@ScriptDir & "\autoitx.html",$rContext[0])
_WinHttpCloseHandle($MyOpen)
Func _DownLoadByResPodn($hRequest)
$hearder=_WinHttpQueryHeaders($hRequest)
$Cookies=StringRegExp($hearder,"Set-Cookie: (xzr_auth=.*?;)",3)
Return $Cookies[0]
EndFunc
|