import requests URL = "https://mindstick.com/forum/"
r = requests.get(URL)
print(r.content)
Parsing the HTML content :
#This will not run on online IDE import requests
from bs4 import BeautifulSoup
URL = "http://www.values.com/inspirational-quotes"
r = requests.get(URL)
soup = BeautifulSoup(r.content, 'html5lib')
print(soup.prettify())
Prakash nidhi Verma
13-Jul-2018Implementing Web Scraping in Python with BeautifulSoup:
Use the API of the website. example: Facebook has the Facebook Graph API which
- allows retrieval of data posted on Facebook.
- HTML of the webpage information/data will access.
Installing the required third-party libraries :
Accessing the HTML content from webpage :
Parsing the HTML content :