PHP - How to determine if my script is running from command line
if (php_sapi_name() == 'cli') {
}
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License