开发者

Is there a way to show html source in the browser after insertion by js?

Is there a w开发者_如何学编程ay to show html source in the browser after insertion by js via ~.innerHTML = Source; ?


If you're working with Firebug/Firefox or with IE8, the DOM viewer can show you the "live" DOM. It's not really "source", but I'm pretty sure that's what you're asking about.

(I didn't mention Safari or Chrome because I don't do much development with those, but they probably have similar facilities. I'm just not personally familiar.)


The WebDeveloper add-on for Firefox among its many useful features also has a 'View Generated Source' feature that works just like view source, but includes the dynamic content. Simple and quick.

https://addons.mozilla.org/en-US/firefox/addon/60/


Pure Firefox without any plugins: select code with mouse -> right-click -> "View Selection Source"

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜