get span text selenium python

Solutions on MaxInterview for get span text selenium python by the best coders in the world

showing results for - "get span text selenium python"
Sofia
03 Apr 2019
1from selenium import webdriver
2browser = webdriver.Firefox()
3browser.get("http://www.google.com")
4for elem in browser.find_elements_by_xpath('.//span[@class = "gbts"]'):
5    print elem.text
6