+<?php
+ require 'include/head.inc';
+ require 'include/db.inc';
+ require 'include/session.inc';
+ require 'include/common.inc';
+
+ block("black", "summary for session " . $SESSIONS[$SESSIONS_actual]['timestr'] . " (" . $SESSIONS[$SESSIONS_actual]['examples'] . ")");
+
+ $result = $db->query("SELECT firstname, lastname, mnumber, blackboard FROM students ORDER BY lastname");
+
+ print "<table>";
+ print "<td><b>First name </b></td><td><b>Last name </b></td><td><b>Matr.nummer </b></td><td><b>Examples </b></td><td><b>Blackboard </b></td>";
+ while ($student = $result->fetch(PDO::FETCH_ASSOC)) {
+ $result2 = $db->query("SELECT manydone, thisdone FROM workdone WHERE mnumber=" . $student['mnumber'] . " AND session=" . $SESSIONS_actual)->fetch(PDO::FETCH_NUM);
+
+ $exdone = $result2[0];
+ if ($exdone == "") { $exdone=0; }
+
+ $thisdone = $result2[1];
+
+ print "<tr>";
+ print "<td>" . $student['firstname'] . "</td>";
+ print "<td>" . $student['lastname'] . "</td>";
+ print "<td>" . $student['mnumber'] . "</td>";
+ print "<td>" . $thisdone . " (" . $exdone . "/" . $SESSIONS[$SESSIONS_actual]['nexamples'] . ")</td>";
+ print "<td>" . $student['blackboard'] . "</td>";
+ print "</tr>";
+ }
+ print "</table>";
+?>
\ No newline at end of file