【发布时间】:2021-04-08 21:38:38
【问题描述】:
我正在尝试编写一个能够自动申请 Indeed.com 上的职位空缺的代码。我已经到了最后一个阶段,但是,最后点击申请表给我带来了很多麻烦。请参考以下页面
登录我的个人资料后,我会转到相关搜索页面,单击我感兴趣的列表,然后在最后一页(如上所示)我尝试使用@987654324 单击continue 按钮@如下:
driver.get("https://in.indeed.com/jobs?q=data%20analyst&l=Delhi&vjk=5c0bd416675cf4e5")
driver.find_element_by_xpath('//*[@id="apply-button-container"]/div[1]/span[1]').click()
driver.find_element_by_xpath('//*[@id="form-action-continue"]')
但是,这给了我一个错误:
Message: no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="form-action-continue"]"}
在网上浏览了一些建议后,我什至尝试了以下方法:
driver.get("https://in.indeed.com/jobs?q=data%20analyst&l=Delhi&vjk=5c0bd416675cf4e5")
driver.find_element_by_xpath('//*[@id="apply-button-container"]/div[1]/span[1]').click()
WebDriverWait(driver, 10).until(EC.presence_of_element_located((By.XPATH, '//*[@id="form-action-continue"]')))
但是这给了我一个超时错误
TimeoutException: Message:
将不胜感激这方面的一些帮助。
【问题讨论】:
标签: python selenium selenium-webdriver xpath webautomation