import requests

# 定义爬取url地址
base_url = 'https://www.baidu.com/'

# 定义代理IP地址
proxies = {'http':'http://121.31.193.38:8123'}

# 使用代理获取想要的页面
response = requests.request('get', base_url, proxies=proxies)

print(response.content.decode('utf-8'))

 

相关文章:

  • 2021-12-03
  • 2021-07-14
  • 2021-12-04
  • 2021-12-19
  • 2021-06-11
  • 2021-06-19
  • 2022-12-23
猜你喜欢
  • 2021-10-07
  • 2021-12-30
  • 2021-12-04
  • 2021-12-23
  • 2021-10-26
  • 2021-03-31
相关资源
相似解决方案