2 // Displays live view of recent logs
4 require_once("../config.php");
5 require_once("lib.php");
11 if (! $course = get_record("course", "id", $id) ) {
12 error("That's an invalid course id");
15 if (! isteacher($course->id
)) {
16 error("Only teachers can view logs");
19 $strlivelogs = get_string("livelogs");
20 $strupdatesevery = get_string("updatesevery", "moodle", COURSE_LIVELOG_REFRESH
);
22 print_header("$strlivelogs ($strupdatesevery)", "$strlivelogs", "", "",
23 "<META HTTP-EQUIV='Refresh' CONTENT='".COURSE_LIVELOG_REFRESH
."; URL=loglive.php?id=$id'>");
28 print_log($course, $user, $date, "ORDER BY l.time DESC");