Reputation: 21200
Some web page's dom is generated dynamically by Javascript, any tool can output the generated html source?
Upvotes: 0
Views: 134
Reputation: 122906
Firebug or the Chrome developer tools can show you the real life DOM-tree. In Firebug you can select an element and use right click to copy it's innerHTML to the clipboard. In Google Chrome Developer tools you can right click on an element and choose 'copy as html' to copy it's innerHTML to the clipboard.
In IE>=8 you can use the web development helper (type F12 from within a page), but you have to refresh the HTML manually after every change on a page. After that you can select an element in the DOM-tree (e.g. <body>
) and choose 'view' > 'source' > 'element source with style'.
Firefox has a nice feature: if you select a part of the page and right click you can select 'view selection source': that shows the current source (so also generated source) of a selection.
Upvotes: 4