diff --git a/htdocs/demo/report/index.php b/htdocs/demo/report/index.php index d205cfcc7..91cfc5987 100644 --- a/htdocs/demo/report/index.php +++ b/htdocs/demo/report/index.php @@ -69,10 +69,11 @@ $parsed = array(); $xml = simplexml_load_string($output); foreach ($xml->errors->error as $error) { //for all errors... + $severity = (string)$error->attributes()->severity; $msg = (string)$error->attributes()->msg; $line = (string)$error->location->attributes()->line; - if (!empty($msg) && !empty($line)) { //if complete error... - $parsed[$line][] = $msg; + if (!empty($severity) && !empty($msg) && !empty($line)) { //if complete error... + $parsed[] = array('severity' => $severity, 'msg' => $msg, 'line' => $line); } } return $parsed; @@ -106,16 +107,23 @@ echo "
Line | Severity | Message |
---|---|---|
" . htmlspecialchars($result['line']) . " | " . htmlspecialchars($result['severity']) . " | " . htmlspecialchars($result['msg']) . " |
No errors found.
\n"; } - echo "Use the online demo page to create the report.
\n"; diff --git a/htdocs/site/css/all.css b/htdocs/site/css/all.css index 1f9520a9b..3e959073c 100644 --- a/htdocs/site/css/all.css +++ b/htdocs/site/css/all.css @@ -136,8 +136,29 @@ pre.code em { border: 1px solid #e2e2e2; } +/* Results table */ +table.results { + border-collapse: collapse; +} +table.results th { + padding: .25em; + text-align: left; + background: #e2e2e2; + border: 1px solid #e2e2e2; +} +table.results td { + padding: .25em; + background: #f7f7f7; + border: 1px solid #e2e2e2; +} +table.results .center { + text-align: center; +} + /* Printing */ @media print { #header { color: black; border-bottom: 1px solid black; } #tabs { display: none; } + table.results th { background: white; border: 1px solid black; } + table.results td { background: white; border: 1px solid black; } } \ No newline at end of file