I am trying to scrape an html table which has two frames. When switching to the first one, the code works well but when switching to default and then to the second frame, I can´t get the full html code.
driver = webdriver.Chrome('/Users/Administrador/Documents/chromedriver')
main_url = 'https://www.justiciacordoba.gob.ar/Estatico/JEL/Escrutinios/ReportesEleccion20190512/default.html'
driver.get(main_url)
#This works fine:
driver.switch_to.frame("topFrame")
# This doesnt:
driver.switch_to.default_content()
driver.switch_to.frame('mainFrame')
page = driver.page_source
page
Output:
'<html><head></head><body></body></html>'