摘要: wd = webdriver.Chrome(r'd:\webdrivers\chromedriver.exe') element = wd.find_element_by_id('kw') --根据ID属性定位元素 element.send_keys('黑羽魔巫宗\n') --发送内容 elemen 阅读全文
posted @ 2020-11-14 21:42 wuli1314 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 参考:https://blog.csdn.net/weixin_36279318/article/details/79475388 要找到目标元素,通过浏览器检查的方式或者按F12键,找到该控件元素,通过其ID、class等属性,能够唯一定位到该元素。 Selenium提供了8种定位方式。 id n 阅读全文
posted @ 2020-11-14 21:00 wuli1314 阅读(170) 评论(0) 推荐(0) 编辑
摘要: 学习教程: http://www.python3.vip http://www.testclass.net/selenium_python/ 1、安装python和selenium 下载python安装后,添加好环境变量。 本地安装了python2和python3两个版本,其中修改了python3. 阅读全文
posted @ 2020-11-14 18:37 wuli1314 阅读(72) 评论(0) 推荐(0) 编辑