Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

Differences Between: [Versions 310 and 311] [Versions 311 and 400] [Versions 311 and 401] [Versions 311 and 402] [Versions 311 and 403] [Versions 39 and 311]

Base class for quiz report plugins.

Copyright: 1999 onwards Martin Dougiamas and others {@link http://moodle.com}
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 97 lines (4 kb)
Included or required:0 times
Referenced: 1 time
Includes or requires: 0 files

Defines 1 class

quiz_default_report:: (2 methods):
  print_header_and_tabs()
  get_current_group()


Class: quiz_default_report  - X-Ref

Base class for quiz 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".

print_header_and_tabs($cm, $course, $quiz, $reportmode = 'overview')   X-Ref
Initialise some parts of $PAGE and start output.

param: object $cm the course_module information.
param: object $coures the course settings.
param: object $quiz the quiz settings.
param: string $reportmode the report name.

get_current_group($cm, $course, $context)   X-Ref
Get the current group for the user user looking at the report.

param: object $cm the course_module information.
param: object $coures the course settings.
param: context $context the quiz context.
return: int the current group id, if applicable. 0 for all users,