From 880637d273abeeb2fd6c8fc79eb9ef82b758c144 Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Sat, 21 Nov 2009 17:05:21 -0500 Subject: Default to only system information and interfaces widgets. This reduces load time on RSPRO from 9+ seconds to 2.5 --- usr/local/www/includes/functions.inc.php | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'usr/local/www/includes/functions.inc.php') diff --git a/usr/local/www/includes/functions.inc.php b/usr/local/www/includes/functions.inc.php index 509ebff..9bb9ea2 100644 --- a/usr/local/www/includes/functions.inc.php +++ b/usr/local/www/includes/functions.inc.php @@ -167,8 +167,7 @@ function swap_usage() return $swapUsage; } -function mem_usage() -{ +function mem_usage() { $memory = ""; exec("/sbin/sysctl -n vm.stats.vm.v_page_count vm.stats.vm.v_inactive_count " . "vm.stats.vm.v_cache_count vm.stats.vm.v_free_count", $memory); @@ -187,7 +186,7 @@ function update_date_time() { return $datetime; } -function get_interfacestats(){ +function get_interfacestats() { global $config; //build interface list for widget use @@ -222,16 +221,13 @@ function get_interfacestats(){ $new_data .= htmlspecialchars($ifinfo['collisions']) . ","; else $new_data .= "0,"; - - - }//end for return $new_data; } -function get_interfacestatus(){ +function get_interfacestatus() { $data = ""; global $config; @@ -261,4 +257,4 @@ function get_interfacestatus(){ return $data; } -?> +?> \ No newline at end of file -- cgit v1.1