摘要: 首先,单击大家肯定都知道,是这样的: # 获取元素,单击 driver.find_element_by_xpath("//ul[@id='ttForSelect']//span[contains(text(),'selenium')]").click() 那么,如果要实现悬浮、右击、双击操作,怎么办 阅读全文
posted @ 2021-08-28 16:49 毛伢子 阅读(456) 评论(0) 推荐(0)
摘要: 同级别,前面的元素:preceding-sibling 同级别,后面的元素:following-sibling 栗子1:文本值等于‘selenium_add’的span标签的,前面1个元素 //span[text()='selenium_add']/preceding-sibling::span[1 阅读全文
posted @ 2021-08-28 15:35 毛伢子 阅读(834) 评论(0) 推荐(0)