网络爬虫系列视频:
https://edu.csdn.net/course/detail/28645
【四二学堂】Requests库的head方法

Requests库的head()方法主要用于获取HTML网页头信息,相当于HTTP的HEAD。例如,抓取百度首页的头部信息,示例代码如下:
【四二学堂】Requests库的head方法
{‘Cache-Control’: ‘private, no-cache, no-store, proxy-revalidate, no-transform’, ‘Connection’: ‘keep-alive’, ‘Content-Encoding’: ‘gzip’, ‘Content-Type’: ‘text/html’, ‘Date’: ‘Sat, 18 Apr 2020 10:24:26 GMT’, ‘Last-Modified’: ‘Mon, 13 Jun 2016 02:50:05 GMT’, ‘Pragma’: ‘no-cache’, ‘Server’: ‘bfe/1.0.8.18’}

【四二学堂】Requests库的head方法

相关文章:

  • 2022-12-23
  • 2021-10-05
  • 2021-10-28
  • 2021-05-18
  • 2021-11-22
  • 2021-12-31
  • 2022-12-23
  • 2021-08-18
猜你喜欢
  • 2021-05-17
  • 2021-07-23
  • 2021-08-27
  • 2021-06-20
  • 2021-05-30
  • 2021-04-06
  • 2021-12-22
相关资源
相似解决方案