from BeautifulSoup import BeautifulSoup import urllib2 content = url.read() soup = BeautifulSoup(content) links = soup.findAll("a") 複製代碼