How can I get the text out of a map pop-up box based on leafletjs. The url is this. I also get this error: NoSuchElementException
If I searched for parcel and entered the relevant information as seen below, then I want to get all the text on the box with class_name: 'leaflet-popup-content'?
# Creates an instance driver object...
driver = webdriver.Chrome()
# load the url above
driver.get(url)
# =============
# Find and fill SEARCH BOX by id....
driver.find_element_by_id('searchBox').send_keys('1083CX')
# Send the form by clicking on the searcht botton...
driver.find_element_by_id('searchButton').click()
driver.find_element_by_id('listElementContent0').click()
# driver.find_element_by_class_name('content').click()
# =============
txt = driver.find_element_by_class_name('leaflet-popup-content').text()
print (txt)
This anser to the question at What is the best way to avoid NoSuchElementException in Selenium? made use of Java, which I don't understand. I am using Python and am new to all this?