python get html info
from bs4 import BeautifulSoup
my_HTML = #Some HTML file (could be a website, you can use urllib for that)
soup = BeautifulSoup(my_HTML, 'html.parser')
print(soup.prettify())
python get html info
from bs4 import BeautifulSoup
my_HTML = #Some HTML file (could be a website, you can use urllib for that)
soup = BeautifulSoup(my_HTML, 'html.parser')
print(soup.prettify())
web scraper python
>>> raw_html = simple_get('http://www.fabpedigree.com/james/mathmen.htm')
>>> html = BeautifulSoup(raw_html, 'html.parser')
>>> for i, li in enumerate(html.select('li')):
print(i, li.text)
0 Isaac Newton
Archimedes
Carl F. Gauss
Leonhard Euler
Bernhard Riemann
1 Archimedes
Carl F. Gauss
Leonhard Euler
Bernhard Riemann
2 Carl F. Gauss
Leonhard Euler
Bernhard Riemann
3 Leonhard Euler
Bernhard Riemann
4 Bernhard Riemann
# 5 ... and many more...
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us