请求Gooker或其他对IEUDF熟的朋友帮个忙?
这个网站 http://w0.pkland.net/game/ 也就一个表单,NAME值也都标注出来了但在验证码输入框,确无法输入字符进去(暂且不讨论字符是否符合验证码)
写了个初始代码#include <IE.au3>
$oIE = _IECreate ("http://w0.pkland.net/game",0,1,1,0)
_IEAction($oIE,"visible")
_IELoadWait($oIE)
Sleep(3000)
$oForm = _IEFormGetCollection($oIE, "text")
$oQuery = _IEFormElementGetObjByName($oForm, "name")
_IEFormElementSetValue($oQuery, "test")
$oQuery = _IEFormElementGetObjByName($oForm, "password")
_IEFormElementSetValue($oQuery, "123")
$oQuery = _IEFormElementGetObjByName($oForm, "inputrand")
_IEFormElementSetValue($oQuery, "gbfd")
_IELoadWait($oIE)
_IEFormSubmit($oForm, 0)
Sleep(1000)
_IEAction($oIE, "visible")
_IELoadWait($oIE)
[ 本帖最后由 bob 于 2008-5-12 11:22 编辑 ] 你也玩这个游戏,呵呵,我也是这里的玩家,有和你同样的问题。你去Gooker的博客有介绍如何读图片的源码。 #include <IE.au3>
$oIE = _IECreate ("http://w0.pkland.net/game",1)
$oForm = _IEFormGetObjByName ($oIE, "loginform")
$oQuery = _IEFormElementGetObjByName($oForm, "name")
_IEFormElementSetValue($oQuery, "test")
$oQuery = _IEFormElementGetObjByName($oForm, "password")
_IEFormElementSetValue($oQuery, "123")
$oQuery = _IEFormElementGetObjByName($oForm, "inputrand")
_IEDocInsertText($oQuery, "gbfd")
_IELoadWait($oIE)
_IEFormSubmit($oForm, 0)
Sleep(1000)
_IELoadWait($oIE) 谢谢Gooker
_IEDocInsertText确实可以插入文字
但还有个值没去掉 value="输入上面的数字或字母"
按Gooker写的,成了 “输入上面的数字或字母gbfd” #include <IE.au3>
$oIE = _IECreate ("http://w0.pkland.net/game",1)
$oForm = _IEFormGetObjByName ($oIE, "loginform")
$oQuery = _IEFormElementGetObjByName($oForm, "name")
_IEFormElementSetValue($oQuery, "test")
$oQuery = _IEFormElementGetObjByName($oForm, "password")
_IEFormElementSetValue($oQuery, "123")
$oQuery = _IEFormElementGetObjByName($oForm, "inputrand")
_IEAction ($oQuery,"click") ;;; 这句是增加的;;;;;;;;
_IEDocInsertText($oQuery, "gbfd")
_IELoadWait($oIE)
_IEFormSubmit($oForm, 0)
Sleep(1000)
_IELoadWait($oIE) ok,very good!
:face (25):
页:
[1]