Python Selenium iFrame -如何移动鼠标并点击?这里有js的事件。我真的不知道,如何用python selenium制作它。
element_to_hover_over = driver.find_element_by_xpath('/html/body/div/div/section/div/div[1]/div/div/div[1]/div[2]/div')
hover = ActionChains(driver).move_to_element(element_to_hover_over)
hover.perform()我试过这个方法,但不起作用。
发布于 2020-05-26 11:40:49
对我来说pyautogui起作用了。
import pyautogui
pyautogui.click(x,y)您可以通过提供适当的time.sleep()将其与selenium结合使用。
https://stackoverflow.com/questions/52593445
复制相似问题