Closed alexey-detr closed 12 years ago
Hi, I've experienced that not every server has $_SERVER['HTTP_USER_AGENT'] So I want to suggest you to use the php_sapi_name() function to detect the CLI environment.
Thanks!
Hi, I've experienced that not every server has $_SERVER['HTTP_USER_AGENT'] So I want to suggest you to use the php_sapi_name() function to detect the CLI environment.