会员
周边
众包
新闻
博问
闪存
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
乔儿
博客园
首页
新随笔
联系
订阅
管理
2019年3月29日
extract()函数,将selector对象中data的值取出来;extract_first()函数,将列表中第0个selector对象拿出来,然后取data的值。
摘要:
阅读全文
posted @ 2019-03-29 16:59 乔儿
阅读(384)
评论(0)
推荐(0)
编辑
打印出来的文字乱码怎么办(还有一种可能是由于Accept-Encoding: gzip, deflate, br导致的,还有'Content-Encoding: gzip')
摘要: 例如: response = requests.get(url=url,headers=headers) print(response.encoding) text = response.text html = etree.HTML(text) title = html.xpath("//div[c
阅读全文
posted @ 2019-03-29 10:47 乔儿
阅读(1567)
评论(0)
推荐(0)
编辑
公告