From 674a7f07a4bea925d057a31aba943d0ae7fa54d1 Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Wed, 24 Jan 2007 01:50:22 +0000 Subject: Use monitorip if available. --- packages/tinydns/tinydns.inc | 6 +++--- packages/tinydns/tinydns_status.php | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'packages/tinydns') diff --git a/packages/tinydns/tinydns.inc b/packages/tinydns/tinydns.inc index 76152040..623c96e8 100644 --- a/packages/tinydns/tinydns.inc +++ b/packages/tinydns/tinydns.inc @@ -232,13 +232,13 @@ function tinydns_setup_ping_items() { else $row['pingthreshold'] = ""; if($row['monitorip']) - fwrite($fd, ip . "|" . $row['monitorip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); + fwrite($fd, $ip . "|" . $row['monitorip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); else - fwrite($fd, $ip . "|" . $row['failoverip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); + fwrite($fd, $ip . "|" . $monitorip . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); } } if($domain['monitorip']) - fwrite($fd, $ip . "|" . $row['monitorip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); + fwrite($fd, $ip . "|" . $domain['monitorip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); else fwrite($fd, $ip . "|" . $row['failoverip'] . "|3|/usr/local/pkg/tinydns_down.php|/usr/local/pkg/tinydns_up.php|{$pingthreshold}\n"); diff --git a/packages/tinydns/tinydns_status.php b/packages/tinydns/tinydns_status.php index 49f07a10..43c72b7c 100644 --- a/packages/tinydns/tinydns_status.php +++ b/packages/tinydns/tinydns_status.php @@ -115,7 +115,7 @@ foreach($config['installedpackages']['tinydnsdomains']['config'] as $ping) { $msstatus = file_get_contents("/var/db/pingmsstatus/$monitorip"); else $msstatus = "N/A"; - echo $msstatus; + echo "" . $msstatus; echo ""; echo ""; @@ -155,7 +155,7 @@ foreach($config['installedpackages']['tinydnsdomains']['config'] as $ping) { else $msstatus = "N/A"; - echo $msstatus; + echo "" . $msstatus; echo ""; echo ""; } -- cgit v1.2.3