python selenium滑动到指定元素操作2

2019-06-24  本文已影响0人  戒灵

python selenium滑动到指定元素操作
指定到元素xpath为:"//div[contains(@class,'button_{0}')]//input" 的位置

elSlider = driver.find_element_by_xpath("//div[contains(@class,'button_{0}')]//input".format(page_coupon))
ActionChains(driver).move_to_element_with_offset(elSlider, 1, 1).click_and_hold().perform()
ActionChains(driver).release().perform()
旺达.gif
上一篇 下一篇

猜你喜欢

热点阅读