
# 1번 라디오버튼이 클릭 되어있는지 true or false
radio_value = driver.find_element_by_xpath('xpath').get_attribute("checked")
>>> print (radio_value)
>>> true
# value 값 얻기
radio_value = driver.find_element_by_xpath('xpath').get_attribute("value")
>>> print (radio_value)
>>> 1번버튼
'Python > selenium' 카테고리의 다른 글
Python) 멀티프로세싱을 이용한 selenium 웹크롤링 (2) | 2022.02.03 |
---|---|
selenium) 셀레니움 xpath 클릭 안될때 JavaScript 이용 방법 (0) | 2022.01.17 |
selenium) 셀레니움 기본 사용법 (0) | 2022.01.17 |
댓글