moodle/mod/quiz/report/default.php
Tim Hunt f6c7f15883 quiz reports MDL-17388 tweak layout so more useful stuff fits on the first page.
In particular, I think you should be able to see at least the top of the table or results without scrolling, if your monitor is not too small.
2010-08-04 18:45:05 +00:00

38 lines
1.3 KiB
PHP

<?php
////////////////////////////////////////////////////////////////////
/// Default class for report plugins
///
/// Doesn't do anything on it's own -- it needs to be extended.
/// This class displays quiz reports. Because it is called from
/// within /mod/quiz/report.php you can assume that the page header
/// and footer are taken care of.
///
/// This file can refer to itself as report.php to pass variables
/// to itself - all these will also be globally available. You must
/// pass "id=$cm->id" or q=$quiz->id", and "mode=reportname".
////////////////////////////////////////////////////////////////////
// Included by ../report.php
class quiz_default_report {
function display($cm, $course, $quiz) { /// This function just displays the report
return true;
}
function print_header_and_tabs($cm, $course, $quiz, $reportmode="overview") {
global $CFG, $PAGE, $OUTPUT;
/// Define some strings
$strquizzes = get_string("modulenameplural", "quiz");
$strquiz = get_string("modulename", "quiz");
/// Print the page header
$PAGE->set_title(format_string($quiz->name));
$PAGE->set_heading($course->fullname);
echo $OUTPUT->header();
$course_context = get_context_instance(CONTEXT_COURSE, $course->id);
}
}