懂PHP的来帮帮

来源:百度知道 编辑:UC知道 时间:2024/05/04 10:11:36
提示的错误
锘?br /> Strict Standards: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'UTC' for '8.0/no DST' instead in E:\AppServ\www\includes\footer.php on line 3
footer里面的东西
<?php

echo '<div class="footer"><b>'.$name.'</b> '.date('Y').'<b></b>.</div>';
?>

加一句
date_default_timezone_set('Asia/Chongqing');

第3行出错了………………

只是警告,可以屏蔽掉
在文件第一行加上<?php error_reporting(0); ?>

这代码应该没错啊.