Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/techsneeze/dmarcts-report-viewer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTechSneeze <dave@techsneeze.com>2022-07-21 21:02:16 +0300
committerGitHub <noreply@github.com>2022-07-21 21:02:16 +0300
commit19c1ee3f55c19e8e25abadb790a4e9f70f92adc2 (patch)
treef77d59811ebdb367811ca5cc826de918e4d42031
parenta4e2a125ec673ef3c5720d65b2b105f7ee9bc929 (diff)
parent3f175c55c870758ff1bff4abbc83c30bd049a0de (diff)
Merge branch 'master' into pgsql
-rw-r--r--README.md2
-rw-r--r--dmarcts-report-viewer.php13
2 files changed, 14 insertions, 1 deletions
diff --git a/README.md b/README.md
index cc6b52f..e14a2e5 100644
--- a/README.md
+++ b/README.md
@@ -35,7 +35,7 @@ A PHP viewer for DMARC records that have been parsed by [John Levine's rddmarc s
* A working webserver (apache, nginx, ...) with PHP
-* Installed `php-mysql` or `php-pgsql` and `php-dom`
+* Installed `php-mysql` or `php-pgsql` and `php-xml`
### Download dmarcts-report-viewer:
```
diff --git a/dmarcts-report-viewer.php b/dmarcts-report-viewer.php
index 5730a3d..7b42cc6 100644
--- a/dmarcts-report-viewer.php
+++ b/dmarcts-report-viewer.php
@@ -301,6 +301,19 @@ foreach($query as $row) {
$periods[] = sprintf( "%'.04d-%'.02d", $row['year'], $row['month'] );
}
+// When arrays of data do not exist, for example in a new & empty set-up, create empty arrays
+// --------------------------------------------------------------------------
+if(!isset($domains)){
+ $domains = array();
+}
+if(!isset($orgs)){
+ $orgs = array();
+}
+if(!isset($periods)){
+ $periods = array();
+}
+
+
// Generate Page with report list and report data (if a report is selected).
// --------------------------------------------------------------------------
echo html(