Python Selenium:我无法单击此退出按钮

时间:2018-06-24 01:39:10

标签: python python-3.x selenium selenium-webdriver buttonclick

我要单击的确切按钮是:

  1. https://www.bungol.ca/map/location/toronto/

  2. 关闭左侧的属性滑块

  3. 点击工具->打开列表

  4. 单击任何列表,您将获得类似这样的内容:

Image for close button

这就是我想要做的:

<span class="raidListSlotCount">&#8237;77&#8236;/&#8237;100&#8236;</span>

time.sleep(5) #wait for page to fully load
driver.find_element_by_xpath("""/html/body/div[17]/div/div/div/button""").click()

1 个答案:

答案 0 :(得分:-1)

此CSS选择器将执行此操作。

#listingInfoModal button.close