php 每周数据
自已写了一段PHP,发现只能读取当今天的数据,前几天的没显示出来,高手看看应怎改。
<?php@header("content-Type: text/html; charset=utf-8");require_once 'inc/site_config.php';require_once 'inc/db_connections.php';require_once 'inc/function.php';mysql_query('set character set "utf8"');?>无标题文档
- <?php $j = 0; for( $i = 0; $i <7; $i++ ){ //循环输出7天日期 if( (date('N',strtotime('-'.$i.' day'))) < 6 ){ //排除星期六天 echo '
- '.(date('n月d日',strtotime('-'.$i.' day'))).' '; $j++; } } ?>
- 事件
- 前值
- 预期值
- 时间
- 日期
- " target="_blank"><?=$s_arr[$i]['Title']?>
- <?=$s_arr[$i]['qz']?>
- <?=$s_arr[$i]['yqz']?>
- <?=$s_arr[$i]['time']?>
- <?=$s_arr[$i]['AccTime']?>
回复讨论(解决方案)
第101行 的 for( $i = 0; $i 内嵌第130行的 for($i=0;$i
你觉得合理吗?
原来是那里问题,把130行的改成I1解决了。。