title: PHP : Curl a page, apply javascript and save result
body: <p>I research a PHP library that allows to execute javascript code on html content to obtain HTML modified content without browser.</p>
  
  <p>The steps are :</p>
  
  <ol>
  <li>Get a page with curl or file get content</li>
  <li>Apply a javascript script to the page.</li>
  <li>Save the result page in a file on server.</li>
  </ol>
  
  <p>All in one php script.</p>
  
  <p><strong>Edit :</strong></p>
  
  <p>My goal is to get the result of a php web page after applying a javascript function on this page to change some things.</p>
  
  <p>Is there a PHP library that allows to execute the javascript code of a page Without going through a browser, and return the results in HTML?</p>