在PHP代码中调用date函数时,在日志里看到如下报错 PHP Warning: date(): 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 'Asia/Chongqing' for 'CST/8.0/no DST' instead 为什么会出现这样的报错?
处理方法1 ini_set('date.timezone','Asia/Shanghai'); 转载请保留固定链接: https://linuxeye.com/program/2107.html |