惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Schneier on Security
Schneier on Security
D
Darknet – Hacking Tools, Hacker News & Cyber Security
T
Tenable Blog
P
Proofpoint News Feed
V
Vulnerabilities – Threatpost
Project Zero
Project Zero
Latest news
Latest news
S
Schneier on Security
C
Cyber Attacks, Cyber Crime and Cyber Security
T
Threatpost
Simon Willison's Weblog
Simon Willison's Weblog
Cyberwarzone
Cyberwarzone
T
The Exploit Database - CXSecurity.com
C
CERT Recently Published Vulnerability Notes
Spread Privacy
Spread Privacy
Cisco Talos Blog
Cisco Talos Blog
T
Troy Hunt's Blog
S
Secure Thoughts
C
Cisco Blogs
Application and Cybersecurity Blog
Application and Cybersecurity Blog
V2EX - 技术
V2EX - 技术
Hacker News: Ask HN
Hacker News: Ask HN
O
OpenAI News
L
LINUX DO - 最新话题
T
Threat Research - Cisco Blogs
Recent Commits to openclaw:main
Recent Commits to openclaw:main
P
Palo Alto Networks Blog
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
博客园_首页
月光博客
月光博客
博客园 - 【当耐特】
雷峰网
雷峰网
C
CXSECURITY Database RSS Feed - CXSecurity.com
博客园 - 叶小钗
aimingoo的专栏
aimingoo的专栏
L
Lohrmann on Cybersecurity
D
DataBreaches.Net
美团技术团队
B
Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
有赞技术团队
有赞技术团队
D
Docker
Jina AI
Jina AI
The GitHub Blog
The GitHub Blog
H
Hacker News: Front Page
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
AI
AI
Martin Fowler
Martin Fowler
Attack and Defense Labs
Attack and Defense Labs
小众软件
小众软件

博客园 - 世之云枭

网站技术分享 推广:湖南省德谦新材料有限公司 Http://www.paint123.cn CentOS MySQL安装和编译【转帖】 缓存容器类的实现(C#) ReadFreeCache 设计一个高效的网络服务器用户管理类 修改自增字段 C++、Java与C#的命名规范总结 (转) VTL-vm模板的变量用法 - 世之云枭 - 博客园 http://www.cnblogs.com/onlytiancai/archive/2009/04/11/1433456.html 数据库中与c#中的数据类型对照 - 世之云枭 - 博客园 SessionID的正确说明 临时文件 细节决定成败 NVelocity 主从表 自动生成清空数据库的SQL语句 自动生成Insert数据的SQL脚本 分页存储过程 常用的获取最大值
网页内容抓取
世之云枭 · 2012-03-28 · via 博客园 - 世之云枭

#region 构造提交参数   
StringBuilder sb = new StringBuilder();   
sb.AppendFormat("callCount=1");   
sb.AppendFormat("&page=/{0}/members/", urlName);   
sb.AppendFormat("&httpSessionId=");   
sb.AppendFormat("&scriptSessionId=D4DAC4AD9C3BF9B71C82802BDDBA0C25369");   
sb.AppendFormat("&c0-scriptName=CircleBean");   
sb.AppendFormat("&c0-methodName=getNewCircleUsers");   
sb.AppendFormat("&c0-id=0");//保留字符   
sb.AppendFormat("&c0-param0=number:{0}", circleId);//11   
sb.AppendFormat("&c0-param1=number:{0}", pageSize);//数量   
sb.AppendFormat("&c0-param2=number:{0}", pageSize * i);//0,30,60   
sb.AppendFormat("&c0-param3=boolean:true");   
sb.AppendFormat("&batchId={0}", i);   
i++;   
  
//callCount=1   
//page=/dnkxin/members/   
//httpSessionId=   
//scriptSessionId=D4DAC4AD9C3BF9B71C82802BDDBA0C25369   
//c0-scriptName=CircleBean   
//c0-methodName=getNewCircleUsers   
//c0-id=0   
//c0-param0=number:15057111            //(<body onload="MembersPage.init('15057111', '/style/pinkstar/','http://blog.163.com','')">)   
//c0-param1=number:10   
//c0-param2=number:0   
//c0-param3=boolean:true   
//batchId=0  
#endregion   
  
string content = "";   
try  
{   
    httpHelper.ContentType = "text/plain";   
    content = httpHelper.GetHtml(url, cookie, sb.ToString(), true, refUrl);//使用Post方式提交内容,并返回页面结果   
    re = new Regex(circleReg.ToString(), RegexOptions.IgnoreCase | RegexOptions.Singleline | RegexOptions.IgnorePatternWhitespace);   
    mc = re.Match(content);   
}   
catch (Exception ex)   
{   
    LogTextHelper.WriteLine(ex.ToString());   
    break;   
}