Basically, I'm trying to figure out how PHP can be called from a "web server".
I've read the documentation, but it didn't help much.
As far as I can tell, there are three ways to invoke PHP:
- via command line (eg:
php -f "/path/to/script.php"
) - via CGI(??) / via FastCGI (???)
- via a web server (eg: Apache) module
So let's start with CGI. Maybe I'm just blind, but the spec doesn't mention how on Earth the web server passes data (headers & callbacks) to the thing implementing CGI. The situation is even worse with FastCGI.
Next up, we have server-specific modules, which, I don't even know what to search for since all leads end up nowhere.