Get The Href Link After Traversing Through Divs Using Selenium In Python
I am new to Selenium.. I am trying to get the href link which is present inside two div elements
Xpath:
element = driver.find_element_by_xpath("//div[@class='foo xyz']/a") link = element.get_attribute("href")
Css selector:
element = driver.find_element_by_css_selector("div[class='foo xyz']>a") link = element.get_attribute("href")
Post a Comment for "Get The Href Link After Traversing Through Divs Using Selenium In Python"