2021年8月6日

python爬虫笔记(1-2)requests模块实例

摘要: # 需求:获取网页,用requests import requests url = "http://www.baidu.com/" resp = requests.get(url) resp.encoding = "utf-8" # 抓取内容写入文件 with open("mybaidu222.ht 阅读全文

posted @ 2021-08-06 14:50 坐看浮云飘飘飘 阅读(74) 评论(0) 推荐(0) 编辑

python爬虫笔记(1-1)requests模块:请求数据获取响应内容

摘要: 参考: https://blog.csdn.net/qq_37616069/article/details/80376776 https://www.cnblogs.com/zhuosanxun/p/12641052.html requests 继承了urllib2的所有特性,比urllib简洁高效 阅读全文

posted @ 2021-08-06 14:43 坐看浮云飘飘飘 阅读(1446) 评论(0) 推荐(0) 编辑

导航