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 311 and 402] [Versions 311 and 403]

Infected file report

Author: Nathan Nguyen <>
Copyright: Catalyst IT
License: GNU GPL v3 or later
File Size: 260 lines (9 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

infectedfiles_table:: (10 methods):

Class: infectedfiles_table  - X-Ref

Infected file report

__construct($uniqueid, \moodle_url $url, $page = 0, $perpage = 30)   X-Ref
Table constructor

param: int $uniqueid table id
param: \moodle_url $url page url
param: int $page current page
param: int $perpage number or record per page

define_table_columns()   X-Ref
Table columns and corresponding headers

define_table_configs(\moodle_url $url)   X-Ref
Define table configuration

param: \moodle_url $url

get_sql_and_params($count = false)   X-Ref
Builds the SQL query.

param: bool $count When true, return the count SQL.
return: array containing sql to use and an array of params.

query_db($pagesize, $useinitialsbar = true)   X-Ref
Get data.

param: int $pagesize number of records to fetch
param: bool $useinitialsbar initial bar

col_author($row)   X-Ref
Column to display the authors fullname from userid.

param: \stdClass $row the row from sql.
return: string the authors name.

col_reason($row)   X-Ref
Column to display the failure reason.

param: \stdClass $row the row from sql.
return: string the formatted reason.

col_actions($row)   X-Ref
Custom actions column

param: \stdClass $row an incident record.
return: string content of action column.

col_timecreated($row)   X-Ref
Custom time column.

param: \stdClass $row an incident record.
return: string time created in user-friendly format.

display($pagesize, $useinitialsbar, $downloadhelpbutton='')   X-Ref
Display table with download all and delete all buttons

param: int $pagesize number or records perpage
param: bool $useinitialsbar use the bar or not
param: string $downloadhelpbutton help button
return: void