Dor1000
Dor1000

Reputation: 361

How to view HTML source without refreshing the page in Chrome

I need to view all source HTML in plain text in one place. I need it from an already loaded page. CTRL+U (View Source) refreshes the page. The page I'm trying to view can only be accessed via proper form submit. What I really want is for CTRL+U to not refresh the page.

I need the HTML source of an already loaded page added to my clipboard.

Upvotes: 14

Views: 7416

Answers (3)

JohnP2
JohnP2

Reputation: 2197

The only answer is the one Dor1000 provided himself in a comment:

dev tools, elements tab, right click html tag, copy, copy outer html.

He wants the current HTML (after javascript or any other modifications, not the original source HTML).

Upvotes: -1

Tim
Tim

Reputation: 5943

I think none of the other answers really answer your question.

You want the exact response from the server, not the current DOM, and you want it with the exact request headers that was sent the first time.

To do so, open the Chrome Dev Tools and select the "Network" tab.

Network tab in Google Dev Tools

The very first request should be the page you requested. Click it and select the tab "Response" on the right side to get the exact response the server gave you.

Response tab in Network tab

Upvotes: 21

Matriac
Matriac

Reputation: 382

Right click-> inspect element anywhere you want to see the html, it still show the code of all the page ans you can modify the value of html/css directly in it.

Upvotes: 1

Related Questions