Skip to content

Instantly share code, notes, and snippets.

@coblezc
Last active Feb 2, 2017
Embed
What would you like to do?
import bs4
import urllib
url = "https://www.amazon.com/TopHeadwear-Face-Mask-Colors-Black/dp/B00X82QUHY/ref=sr_1_8?ie=UTF8&qid=1486007211&sr=8-8&keywords=black+ski+mask"
html = urllib.urlopen(url).read()
soup = bs4.BeautifulSoup(html, 'html.parser')
titles = soup.select('.review-data')
for title in titles:
print title.text.strip()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment