Web Crawling by BeautifulSoup (1) Posted on 2018-08-16 In Etc. BeautifulSoup란?HTML과 XML을 분석해주는 라이브러리. find_all() 메서드로 <a> 태그 추출하기123456789101112131415161718from bs4 import BeautifulSouphtml = """<html><body> <ul> <li><a href="http://www.naver.com">naver</a></li> </ul></body></html>"""soup = BeautifulSoup(html, 'html.parser')links = soup.find_all("a")for a in links: href = a.attrs['href'] text = a.string print(text, ">", href)