Skip to content Skip to sidebar Skip to footer

Load A Web Page, Execute Its Javascript And Dump Resulting Html To A File

I need to load a web page, execute its JavaScript (and all js files included with the tags) and dump resulting HTLM to a file. This needs to be done on the server. I have tried no

Solution 1:

Perhaps that’s because you are using err.message whereas err is not defined? error, on the other hand, is defined.


Update

Did you check out PhantomJS?

Also, it looks like Aptana Jaxer could do what you want. To quote John Resig:

Imagine ripping off the visual rendering part of Firefox and replacing it with a hook to Apache instead - roughly speaking that's what Jaxer is.

Post a Comment for "Load A Web Page, Execute Its Javascript And Dump Resulting Html To A File"