Detect whether PHP is CLI or Apache
Posted: Mon Dec 01, 2008 11:36 pm
I know it's probably obtainable with some weird checks...using phpinfo() for example but I'm curious incase there is an API which I have overlooked...
Is it possible to detemrine whether PHP instance running is invoked by Apache or CLI?
Will I have to detect this informaiton much like a browser is detected, by checking environment variables, etc.
Hopefully there is a simple API
Is it possible to detemrine whether PHP instance running is invoked by Apache or CLI?
Will I have to detect this informaiton much like a browser is detected, by checking environment variables, etc.
Hopefully there is a simple API