Closed cohhi closed 1 year ago
from selenium import webdriver
from selenium.webdriver.common.by import By
driver = webdriver.Chrome()
driver.get("http://411.free.svipss.top/blog/resources/applicationtest/resources/steam-404/steam-404Selenium.html")
prompt = driver.find_element(by=By.ID, value="contendAlertMessage").click()
message = driver.switch_to_alert()
message.send_keys("ikun")
message.accept()
已解决,向弹窗输入内容时不会显示。
puthon
3.5.0
selenium3.141.0