diff --git a/discovery.php b/discovery.php index a0ba797578..db532afe37 100755 --- a/discovery.php +++ b/discovery.php @@ -111,7 +111,7 @@ if ($discovered_devices) dbInsert(array('type' => 'discover', 'doing' => $doing, 'start' => $start, 'duration' => $proctime, 'devices' => $discovered_devices), 'perf_times'); } -$string = $argv[0] . " $doing " . date("F j, Y, G:i") . " - $discovered_devices devices discovered in $proctime secs"; +$string = $argv[0] . " $doing " . date($config['dateformat']['compact']) . " - $discovered_devices devices discovered in $proctime secs"; if ($debug) echo("$string\n"); if($options['h'] != "new" && $config['version_check']) { diff --git a/includes/defaults.inc.php b/includes/defaults.inc.php index e00bf140e1..170134d6c3 100644 --- a/includes/defaults.inc.php +++ b/includes/defaults.inc.php @@ -573,4 +573,9 @@ $config['update'] = 1; $config['syslog_purge'] = 30; # Number in days of how long to keep syslog entries for. $config['eventlog_purge'] = 30; # Number in days of how long to keep eventlog entries for. +# Date format for PHP date()s +$config['dateformat']['long'] = "r"; # RFC2822 style +$config['dateformat']['compact'] = "Y-m-d H:i:s"; +$config['dateformat']['time'] = "H:i:s"; + ?> diff --git a/poller.php b/poller.php index f9131d65d8..fd91f3d727 100755 --- a/poller.php +++ b/poller.php @@ -118,7 +118,7 @@ if ($polled_devices) dbInsert(array('type' => 'poll', 'doing' => $doing, 'start' => $poller_start, 'duration' => $poller_time, 'devices' => $polled_devices ), 'perf_times'); } -$string = $argv[0] . " $doing " . date("F j, Y, G:i") . " - $polled_devices devices polled in $poller_time secs"; +$string = $argv[0] . " $doing " . date($config['dateformat']['compact']) . " - $polled_devices devices polled in $poller_time secs"; if ($debug) { echo("$string\n"); } echo("\n" .