title: Using Phantom JS to convert all HTML files in a folder to PNG
body: <p>I've started using Phantom JS on Windows, but I'm having a bit of difficulty finding documentation on its capability (probably the root of my problem).  </p>
  
  <p>Using Phantom JS I would like to do the following:</p>
  
  <ol>
  <li>Give it a local machine folder location, </li>
  <li>Have it navigate to that location and identify the list of HTML files, </li>
  <li>Once that list is identified to loop of the the list of HTML files and convert them all to PNG (similar to the way the rasterize.js example works), where the filename gsubs "HTML" with "PNG".   </li>
  </ol>
  
  <p>I'm sure this is probably possible, but I wasn't able to find the Phantom JS function call for:</p>
  
  <ol>
  <li>getting the list of files in a folder and </li>
  <li>the format for gsub and grep in Phantom JS.  </li>
  </ol>