去除 IS_CGI IS_MAC NOW_TIME 常量

This commit is contained in:
thinkphp
2016-06-02 12:21:36 +08:00
parent 8099a001e2
commit d65882e20c
7 changed files with 11 additions and 15 deletions

View File

@@ -40,8 +40,5 @@ defined('CLASS_APPEND_SUFFIX') or define('CLASS_APPEND_SUFFIX', false); // 是
defined('APP_MODE') or define('APP_MODE', 'common'); // 应用模式 默认为普通模式
// 环境常量
define('IS_CGI', strpos(PHP_SAPI, 'cgi') === 0 ? 1 : 0);
define('IS_CLI', PHP_SAPI == 'cli' ? 1 : 0);
define('IS_WIN', strstr(PHP_OS, 'WIN') ? 1 : 0);
define('IS_MAC', strstr(PHP_OS, 'Darwin') ? 1 : 0);
define('NOW_TIME', $_SERVER['REQUEST_TIME']);
define('IS_CLI', PHP_SAPI == 'cli' ? true : false);
define('IS_WIN', strstr(PHP_OS, 'WIN') ? true : false);