In [4]:
import requests
from bs4 import BeautifulSoup

In [5]:
r = requests.get("http://pythonforengineers.com/secret/")
data = r.text
soup = BeautifulSoup(data)

In [9]:
for link in soup.find_all('p'):
    print link.getText()


Nothin' to see here! Move along please. Thank you
Your email address will not be published. Required fields are marked *
Name * 
Email * 
Website 
Comment 
You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> 







· © 2015 Python For Engineers · Designed by Themes & Co ·
Back to top


In [22]: