With regard to the problem of selenium pop-up window, how to extract the content of this form of pop-up window?


a = driver.switch_to.alert
a.accept ()
if you write in this way, you will report an error Message: no alert open

Mar.09,2021

this is the dom element, not the native pop-up window of the browser. Get


driver.find_element_by_xpath ("XPath value"). Text

) through the selector.
Menu