Contenuti del Corso
Automating Data Collection from Web Sources
The Requests Library
The requests library is a popular Python library for making HTTP requests. It allows you to send HTTP requests to a website's server and retrieve the server's response.
In the context of web scraping, the requests library can be used to send an HTTP request to a website's server to retrieve the HTML content of a webpage. This is often the first step in the web scraping process, as the HTML content contains all the data that you want to extract.
Compito
Swipe to start coding
- Import the
requestslibrary. - Use the
requestslibrary to retrieve the content of the website (url). - Save the text (the
.textattribute) in anhtmlvariable.
Once you've completed this task, click the button above the code to check your solution.
Soluzione
Mark tasks as Completed
Tutto è chiaro?
Grazie per i tuoi commenti!
Sezione 1. Capitolo 2
AVAILABLE TO ULTIMATE ONLY