diff options
Diffstat (limited to 'src/usr/local/www/index.php')
-rw-r--r-- | src/usr/local/www/index.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/usr/local/www/index.php b/src/usr/local/www/index.php index 9ef6373..3d7a0d0 100644 --- a/src/usr/local/www/index.php +++ b/src/usr/local/www/index.php @@ -328,8 +328,13 @@ pfSense_handle_custom_code("/usr/local/pkg/dashboard/pre_dashboard"); <?php // Build the Available Widgets table using a sorted copy of the $widgets array +// Can't just ksort because the "Firewall Logs" widget has a key of "logs" $available = $widgets; -ksort($available); +function widgetcompare($w1, $w2) { + return ($w1['name'] < $w2['name']) ? -1:1; +} + +usort($available, 'widgetcompare'); foreach ($available as $widgetname => $widgetconfig): if ($widgetconfig['display'] == 'none'): |