I’m trying to get PhantomJS to run via PHP.
When I run the JavaScript file directly through the command line, it works fine. When I run php render_html.php
in the command line, which just runs an exec(), it works fine. However, when I try opening this php file in the browser, it does nothing. I don’t even get anything back to echo.
I’ve done all this testing locally on OS X, and on my EC2 server, and I get the same result.
Advertisement
Answer
It might be a permission problem, check if the user running the web server has permission to run the phantomjs executable.