Web crawler作业报告[7]

[入库:2005年8月19日] [更新:2007年3月24日]

本文简介:选择自 askmyself 的 blog

3)       string get_head(curl url):建立对url所在的hostsocket连接,发送请求"head "+url.str()+""+" http/1.0\n\n"revc应答头。函数以string类型返回应答头信息。

4)       int  isdeadlink(curl url):调用get_head(url),查看返回的应答头中的status状态信息是否>=400,若是,则断定为死链,返加1,否则返回0

5)       string content_type(curl url):调用get_head(url),取出返回的应答头中的content-type信息,并返回此信息。

本文关键:Web crawler作业报告
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top