[C#] 纯文本查看 复制代码 HttpHelper http = new HttpHelper();
HttpItem item = new HttpItem()
{
URL = "http://www.sufeinet.com",//URL这里都是测试 必需项
Encoding = null,//编码格式(utf-8,gb2312,gbk) 可选项 默认类会自动识别
//Encoding = Encoding.Default,
Method = "get",//URL 可选项 默认为Get
};
//得到HTML代码
HttpResult result = http.GetHtml(item);
item = new HttpItem()
{
URL = "http://tool.sufeinet.com",//URL这里都是测试URl 必需项
Encoding = null,//编码格式(utf-8,gb2312,gbk) 可选项 默认类会自动识别
//Encoding = Encoding.Default,
Method = "get",//URL 可选项 默认为Get
Cookie = result.Cookie,
};
//得到新的HTML代码
result = http.GetHtml(item);
这个我看过了,可能我没有仔细看,
就是这句 Cookie = result.Cookie,把上次请求返回的cookie全部传当做http参数,是不? |