开发者

Get source code after JS has run

I'm trying to retrieve the source code of a page, but the problem is that some of the content loads through AJAX or similar.. this content doesn't appear in the 开发者_Python百科normal source code fetched through PHP's file_get_contents.

Is there any way to get this? (On the server side, not via browser developer tools and such.)


Try the Web Developer extension for firefox. You can right click a page and click "View Generated Source" from one of the Web Developer options.

Hope this is what you needed.


When ever i need to test this i use something like FireBug (for firefox but there's a 'light' version that can be used on other browsers).

Firebug is great for this since it will show you the exact code (html, javascript,..) that the browser is using to generate the page

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜