Home > Blockchain >  How do I click this link using Selenium (Python)
How do I click this link using Selenium (Python)

Time:06-18

How do I click this link using Selenium in Python? I've been able to get to the webpage using Selenium and click other links that have IDs. But this one doesn't have an ID or name.

<li ng->
  <a href="#" ng-click="tabDetailsNavigationClick('overview')">
     Overview
  </a>
</li>

CodePudding user response:

Try:

WebDriverWait(driver,20).until(EC.element_to_be_clickable((By.XPATH,'//a[contains(.,"Overview")]'))).click()
#imports
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
  • Related