Only the following pseudo-classes are implemented: nth-of-type.selenium
구글 크롬 개발자도구에서 셀렉터 카피에서 나오는 child 선택자인 nth-child 를 지원하지 않는다.
tr:nth ->nth-of-type 으로 바꿔준다.
# F12를 눌러 copy -> copy selector 를 할 경우.
# 기존
soup.select('#tblSort > tbody > tr:nth-child(1) > td:nth-child(5)')
# 변경
soup.select('#tblSort > tbody > tr:nth-of-type(1) > td:nth-of-type(5)')
'Study > Code' 카테고리의 다른 글
python 파일 이름 변경. os.rename (0) | 2018.12.01 |
---|---|
Python Google translate, py_translator (0) | 2018.11.27 |
python 출력 입력 값 받기. (0) | 2018.11.19 |
Python MM1 queue 파이썬MM1 큐잉 시스템 병렬 (0) | 2018.11.15 |
Python MM1 queue 파이썬MM1 큐잉 시스템. (2) | 2018.11.01 |