summaryrefslogtreecommitdiffstats
path: root/usr/local/www/includes/functions.inc.php
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2010-10-07 09:29:30 -0400
committerjim-p <jimp@pfsense.org>2010-10-07 09:29:30 -0400
commit5af7eba3ef401e9dd183a3e1d17c98f8fbf67cb1 (patch)
tree1ae955e498a3976f9b0eeba09b53c8cd90cbdbd2 /usr/local/www/includes/functions.inc.php
parent7e1cf139c389e4eb6aaf4e26c8dc6660137b7e1a (diff)
downloadpfsense-5af7eba3ef401e9dd183a3e1d17c98f8fbf67cb1.zip
pfsense-5af7eba3ef401e9dd183a3e1d17c98f8fbf67cb1.tar.gz
Fix AJAX update of gateway status when the status is "Gathering Data".
Diffstat (limited to 'usr/local/www/includes/functions.inc.php')
-rw-r--r--usr/local/www/includes/functions.inc.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/usr/local/www/includes/functions.inc.php b/usr/local/www/includes/functions.inc.php
index b013cc8..6769d0e 100644
--- a/usr/local/www/includes/functions.inc.php
+++ b/usr/local/www/includes/functions.inc.php
@@ -37,9 +37,7 @@ function get_gatewaystats() {
$data .= lookup_gateway_ip_by_name($gname) . ",";
if ($gateways_status[$gname]) {
$gws = $gateways_status[$gname];
- $data .= $gws['delay'] . ",";
- $data .= $gws['loss'] . ",";
- switch(strtolower($gws['status'])) {
+ switch(strtolower($gws['status'])) {
case "none":
$online = "Online";
$bgcolor = "lightgreen";
@@ -64,6 +62,7 @@ function get_gatewaystats() {
$online = "Gathering data";
$bgcolor = "lightgray";
}
+ $data .= ($online == "Gathering data") ? "{$online},{$online}," : "{$gws['delay']},{$gws['loss']},";
$data .= "<table><tr><td bgcolor=\"$bgcolor\" > $online </td></td></tr></table>";
}
return $data;
OpenPOWER on IntegriCloud