“Date():依赖系统的时区设置…是不安全的”

“Date():依赖系统的时区设置…是不安全的”

请求更新PHP服务器上的版本从5.2.17到PHP 5.3.21。

<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">


<h4>A PHP Error was encountered</h4>


<p>Severity: Warning</p>

<p>Message:  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 'America/New_York' for 'EDT/-4.0/DST' instead</p>

<p>Filename: libraries/Log.php</p>

<p>Line Number: 86</p>


</div>

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 'America/New_York' for 'EDT/-4.0/DST' instead in /filelocation right here/system/libraries/Log.php on line 86


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 'America/New_York' for 'EDT/-4.0/DST' instead in /filelocation right here/system/libraries/Log.php on line 99

<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">


<h4>A PHP Error was encountered</h4>




温温酱
浏览 802回答 3
3回答

胡子哥哥

在您的index.php档案。我第一次发现这一点是因为我把我的应用程序从我的XAMPP服务器到Apache 2.2和PHP 5.4.。我建议你用你的index.php文件,而不是php.ini档案。if(&nbsp;!&nbsp;ini_get('date.timezone')&nbsp;){ &nbsp;&nbsp;&nbsp;&nbsp;date_default_timezone_set('GMT');}
打开App,查看更多内容
随时随地看视频慕课网APP