This excellent, albeit somewhat outdated, book from Sara Golemon has the answers to most of your questions. Otherwise, the best way to learn the internal components of php is to compile its debug version and execute it step by step under the debugger. I did it once, and it was an exciting experience.
user187291
source share