BeautifulSoup 와 selenium 으로 웹크롤링 할때 데이터를 못 읽어오는건 어떻게 해결할수있을까요?
조회수 2203회
from bs4 import BeautifulSoup
from selenium import webdriver
driver = webdriver.Firefox()
driver.get("http://ntry.com/#/stats/ladder/date.php?date=2014-01-04")
html = driver.page_source
soup = BeautifulSoup(html, "html.parser")
prodList = soup.find_all("td", {"class": "round_cell"})
print(prodList)
실행시 결과값이 [ ] 나오내요.
-
(•́ ✖ •̀)
알 수 없는 사용자 - 〉
1 답변
-
BeautifulSoup으로 웹크롤링 할때 데이터를 못 읽어오는건 어떻게 해결할수있을까요?에 달린 답변을 그대로 따라하신것 같은데요. 올려주신 코드대로 하면 html을 읽어오는것까지는 잘 동작 합니다.
그런데 소스코드에 보면 td라는 태그도 없고, round_cell이라는 클래스를 가진 element도 없네요. 찾는 내용을 잘 명시해 보세요.
댓글 입력