使用鼠标模拟操作需要倒入
from selenium.webdriver.common.action_chains import ActionChains
- 将鼠标悬停到某个元素
ele = driver.find_element(By.ID,"s-usersetting-top") ActionChains(driver).move_to_element(ele).perform()
使用鼠标模拟操作需要倒入
from selenium.webdriver.common.action_chains import ActionChains
ele = driver.find_element(By.ID,"s-usersetting-top")
ActionChains(driver).move_to_element(ele).perform()