望苏飞大哥给指定下。
[C#] 纯文本查看 复制代码
HttpItem item = new HttpItem()
{
KeepAlive = false,
Accept = "image/jpeg, application/x-ms-application, image/gif, application/xaml+xml, image/pjpeg, application/x-ms-xbap, */*",
UserAgent = "Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0)",
ProtocolVersion = HttpVersion.Version10,
Host = "upay.10010.com",
Referer = "https://upay.10010.com/web/Buycard/BuycardInit?MediaCardAmount=1&MediaCardCode=01&&menuId=000200030001",
Method = "POST",
PostDataType = Utilities.PostDataType.Byte,
PostdataByte = Encoding.UTF8.GetBytes(postData),
//Postdata = string.Format(postData, cardNum, State, verifyCode),
URL = url,//URL必需项
ResultCookieType = Utilities.ResultCookieType.CookieCollection,
CookieCollection = UnicomCookie,
//Encoding = null,//编码格式(utf-8,gb2312,gbk)可选项 默认类会自动识别
Encoding = UTF8Encoding.UTF8,
ResultType = ResultType.String,
ContentType = "application/x-www-form-urlencoded"
};
POST的数据我也和Fiddler2抓包后的数据对比了下,没有什么问题啊。result.StatusCode也是OK,就是取回来的页面不是我想要的界面说我验证码错误,实际上验证码数据的没有错误的。
|