Skip to content

Instantly share code, notes, and snippets.

@vivosmith
Created September 26, 2016 23:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vivosmith/a593089e176be195c377b67a3a0758c6 to your computer and use it in GitHub Desktop.
Save vivosmith/a593089e176be195c377b67a3a0758c6 to your computer and use it in GitHub Desktop.
from urllib.request import urlopen
from bs4 import BeautifulSoup
class ehow:
link_collector=[]
url = urlopen("http://www.ehow.com").read()
soup = BeautifulSoup(url,"html.parser")
for line in soup.find_all('a'):
link_collector=line.get('href')
print(link_collector)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment