Given below is an image of a basic PHP web server architecture:
Would someone please explain the several components available and how they interact?
I’m more concerned of how the PHP Core operates and relates to the other components, so feel free to elaborate on this point specifically.
This Diagram was taken from here.
13
Very roughly:
- SAPI transfers (and translates) the data received by the http daemon (but not necessarily only it, see Wikipedia) to the PHP framework
- PHP Core is the “basic” functionality provided by the language (e.g. what allows you to use
echo $variable
) - PHP API is additional functionality you can use to access separate services (e.g. a database) – the exact line between those two is a bit fuzzy (imho)
- ZEND is the engine that actually executes the PHP scripts (compiler and runtime environment) – see wikipedia again.
2