If you are running your home server on a Mac or have suEXEC enabled, there are security measures in place to strip any non-http environment variables that are defined, therefore they won t appear in $_ENV[ APPLICATION_ENV ]. You CAN, however access these through a PHP function to get the same thing.
$var = apache_getenv( APPLICATION_ENV );
如果你想要,即使不建议,你甚至可以确定植物检疫中的环境变量。
$_ENV[ APPLICATION_ENV ] = apache_getenv( APPLICATION_ENV );
I have an almost identical config to what you have, and we just define a global:
define( APPLICATION_ENV , apache_getenv( APPLICATION_ENV ));
一旦你这样做,它就应当按照期望开展工作。