110,537
社区成员
发帖
与我相关
我的任务
分享
<p class="common-captcha" id="captcha" style="margin-top:10px">
<input type="hidden" id="uuid" name="uuid" value="7d6a3d47-44a5-4099-a2c3-7932f9eec84e" />
<input id="verifyCode" placeholder="验证码" type="text" class="common-text" name="verifyCode" autocomplete="off" maxlength="4">
<img id="imgObj" src="verifyCodeServlet?uuid=7d6a3d47-44a5-4099-a2c3-7932f9eec84e" width="100" height="50"> <a href="javascript:" onclick="changeImg()"><span style="height:50">换一张</span></a>
</p>
我用如下代码还是不能正确登陆。 其中 txt_img.Text 是上面的uuid内容,txt_img.Text 是访问
verifyCodeServlet?uuid=7d6a3d47-44a5-4099-a2c3-7932f9eec84e 后得到的验证码信息。
string uriString = "http://xxx.xxx.com/xxx/login.action";
string postData = "userName=myname&userPass=000000&uuid=" + "&verifyCode=" + txt_img.Text + "&uuid=" + txt_Uuid.Text;
HttpHelper httpHelper = new HttpHelper();
this.webBrowser_Main.DocumentText = httpHelper.PostDataToString(uriString,postData, ref nowCookies);