Is there a way to ensure that the webpage HTML is displayed accurately after it loads the javascript? I need this in order to get a proper representation of the tables.
I have experimented with various JavaScript libraries, but so far only one seems to be effective for me as the others appear to be outdated.
System.setProperty("webdriver.chrome.driver", "D:\\Download bestanden\\chromedriver_win32\\chromedriver.exe");
ChromeOptions options = new ChromeOptions();
//options.addArguments("headless");
WebDriver driver = new ChromeDriver(options);
driver.get("https://www.flashscore.com/");
System.out.println(driver.getTitle());
Document doc = Jsoup.parse(driver.getPageSource());
System.out.println(doc.select("ul.submenu.hidden li a").text());
driver.close();
driver.quit();
System.out.println("Completed");
When searching for lmenu_17, I am expecting results beyond just Superlinga from Albania as an href. In the inspector, First Division Albanian cup and Super Cup are also visible. I hope to see these results reflected in the search. Any assistance on this matter would be greatly appreciated!