6
回答
php.ini无法修改date.timezone
终于搞明白,存储TCO原来是这样算的>>>   
/php -i | grep ini
Configuration File (php.ini) Path => /usr/local/php/lib
Loaded Configuration File => /usr/local/php/lib/php.ini

修改/usr/local/php/lib/php.ini里的date.timezone

date.timezone = "Asia/Shanghai"

重启nginx php-fpm后phpinfo()里还是显示

Warning: phpinfo(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set

PHP
举报
大黄
发帖于4年前 6回/1K+阅
顶部