Answers for "how to use python to download files from the interent"

0

how to use python to download files from the interent

import requests


url = 'https://www.facebook.com/favicon.ico'
r = requests.get(url, allow_redirects=True)

open('facebook.ico', 'wb').write(r.content)

#####################output################
the file facebook.ico was created in the python folder
Posted by: Guest on April-10-2021

Code answers related to "how to use python to download files from the interent"

Python Answers by Framework

Browse Popular Code Answers by Language