Saving the page HTML in Chrome without reloading

This chestnut can drive developer crazy.  In Google Chrome hitting “save as” or “view source” will reload the page.  On pages where sessions or cookies are cleared (shop checkouts for example), form data is submitted, or the like, then the reloaded source may no-longer be the same as the page you were just looking at.  Argh. Here is my solution to the issue.

In the Chrome developer tools, in the elements tab, right click on the opening html tag and choose “copy > copy outer HTML” and then paste into the clipboard. This will show all the html, including that generated by scripts, and let you see the final rendered html without reloading the page.  Note that this might be slightly different from the actual source as things added by document.write or similar javascripts will be there as elements.  However this is the closest I can get without adding plugins to the site.  Hope that helps.

Facebook Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Apply your human brain cells and complete this highly complicated maths problem *