import requests

#通过url获取数据
def get_page(url):
    #requests.get 自带 json.load
    page = requests.get(url)
    page = page.content
    #将bytes转换成字符串
    page = page.decode('utf-8')
    return  page

print(get_page('https://www.duitang.com/napi/blog/list/by_search/?kw=%E6%A0%A1%E8%8A%B1&start=0&limit=1000'))

相关文章:

  • 2021-11-30
  • 2022-12-23
  • 2023-03-19
  • 2021-11-25
  • 2022-12-23
  • 2021-05-04
  • 2022-01-09
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-09-18
  • 2022-12-23
  • 2021-07-20
  • 2022-12-23
  • 2021-12-07
相关资源
相似解决方案