I am trying to automate the log in process to WebAdvisor. I have tried to select the "Log In" button by calling different elements. Each attempt so far has been unsuccessful.
Your xpath is wrong, Please find below solution.
fromseleniumimportwebdriverfromtimeimportsleepfromselenium.webdriver.supportimportexpected_conditionsasECfromselenium.webdriver.support.uiimportWebDriverWaitfromselenium.webdriver.common.byimportBy driver = webdriver.Chrome(executable_path=r"chromedriver.exe") driver.get("https://webadvisor.barry.edu/") element=WebDriverWait(driver,20).until(EC.visibility_of_element_located((By.XPATH,"//li[@id='acctLogin']//span[@class='label'][contains(text(),'Log In')]"))) element.click() element0=WebDriverWait(driver,20).until(EC.visibility_of_element_located((By.XPATH,"//input[@id='USER_NAME']"))) element0.send_keys("Test123")