webdriver根据class_name获取元素
#encoding = utf-8 import time from selenium import webdriver from selenium.webdriver.common.by import By driver = webdriver.Chrome() #打开百度首页 driver.get("https://www.baidu.com") #根据class_name获取元素 driver.find_element(by=By.CLASS_NAME,value="s_ipt").send_keys('python') time.sleep(6)
标签:webdriver,name,driver,获取,import,class From: https://www.cnblogs.com/dongtian/p/17496950.html