echo "<table>\n\t\t\t<thead>\n\t\t\t\t<tr>\n\t\t\t\t\t<th>学号</th>\n\t\t\t\t\t<th>姓名</th>\n\t\t\t\t\t<th>分数</th>\n\t\t\t\t\t<th>排名</th>\n\t\t\t\t</tr>\n\t\t\t</thead>\n\t\t\t<tbody>"; for ($i = 0; $i < count($arr); $i++) { echo "<tr>"; for ($j = 0; $j < count($arr[$i]); $j++) { echo "<td>{$arr[$i][$j]}</td>"; } echo "</tr>"; } echo "</tbody>\n\t\t</table>"; } $study = $orderDao->getStudyScho($user_id); $spiritual = $orderDao->getSpiritualScho($user_id); $activity = $orderDao->getActivityScho($user_id); $work = $orderDao->getWorkScho($user_id); $scie_tech = $orderDao->getScieTechScho($user_id); $practice = $orderDao->getPracticeScho($user_id); echo "<h3>学习优秀奖学金</h3>"; echo "<table>\n\t\t\t<thead>\n\t\t\t\t<tr>\n\t\t\t\t\t<th>学号</th>\n\t\t\t\t\t<th>姓名</th>\n\t\t\t\t\t<th>成绩排名</th>\n\t\t\t\t\t<th>奖学金类型</th>\n\t\t\t\t</tr>\n\t\t\t</thead>\n\t\t\t<tbody>"; for ($i = 0; $i < count($study); $i++) { echo "<tr>"; for ($j = 0; $j < count($study[$i]); $j++) { echo "<td>{$study[$i][$j]}</td>"; } echo "</tr>"; } echo "</tbody>\n\t\t</table>"; echo "<h3>精神文明奖学金</h3>"; printTable($spiritual); echo "<h3>文体活动奖学金</h3>"; printTable($activity); echo "<h3>社会工作奖学金</h3>";