The page I'm trying to scrape (for practice) is the url
below. I'm trying to scrape the income-statement (chart) on the bottom of the page
import time
from selenium import webdriver
from selenium.common.exceptions import NoSuchElementException
browser = webdriver.PhantomJS()
url = 'https://seekingalpha.com/symbol/CYTR/financials/income-statement'
browser.get(url)
time.sleep(7)
I've tried the various methods but it's not locating the element.
browser.find_element_by_xpath("//*[@id='industrial-income-statement']")
#copied the xpath via chrome
browser.find_element_by_xpath('//*[@id="financial-data"]')
#returns error
browser.find_elements_by_id("financial-data")
# returns an empty list
browser.find_element_by_id("industrial-income-statement")
#can't find error
I know I'm receiving the page info because 'browser.find_elements_by_id('div')' returns a list of elements.