Tuesday 15 July 2014

PhantomJS load blank page and run script -


Is it possible for some JavaScript to load and execute an empty page on this page? if so, how? Examples would be appreciated.

PhantomJS requires a DOM and will not exist on an empty file. You need to create at least this structure to execute javascript on the page:

  & lt; Html & gt; & Lt; Top & gt; & Lt ;! - Javascript goes here! - & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; / Body & gt; & Lt; / Html & gt;    

No comments:

Post a Comment