diff --git a/lib/reports.php b/lib/reports.php index ed8705b..38115eb 100644 --- a/lib/reports.php +++ b/lib/reports.php @@ -208,6 +208,14 @@ function dataToODS($data, $name = "report") { } function dataToHTML($data, $name = "report") { + // HTML exporter doesn't like null values + for ($i = 0; $i < count($data); $i++) { + for ($j = 0; $j < count($data[$i]); $j++) { + if (is_null($data[$i][$j])) { + $data[$i][$j] = ''; + } + } + } header('Content-type: text/html'); $converter = new HTMLConverter(); $out = "\n"