How can I view the source of a page between the \"title\" and \"meta\" tags using Selenium WebDriver with Java?
You can try driver.getPageSource() after you have loaded the page.
driver.getPageSource()
link to java doc