diff --git a/html/includes/print-menubar.php b/html/includes/print-menubar.php
index 1a4748908..62e6d97d6 100644
--- a/html/includes/print-menubar.php
+++ b/html/includes/print-menubar.php
@@ -67,11 +67,15 @@ if ($_SESSION['userlevel'] >= '10') {
}
?>
+
+
All Devices(" . $rows . ")
";
+}
+else {
+ $sql = "SELECT D.`hostname`,D.`device_id`,D.`status`,D.`uptime` FROM `devices` AS D, `devices_perms` AS P WHERE D.`device_id` = P.`device_id` AND P.`user_id` = '" . $_SESSION['user_id'] . "' AND D.`ignore` = '0' AND D.`disabled` = '0' ORDER BY D.`hostname`";
+ $sqlcount = "SELECT COUNT(*) FROM `devices` AS D, `devices_perms` AS P WHERE D.`device_id` = P.`device_id` AND P.`user_id` = '" . $_SESSION['user_id'] . "' AND D.`ignore` = '0' AND D.`disabled` = '0' ORDER BY D.`hostname`";
+ $rows = dbFetchCell($sqlcount);
+ echo "
";
\ No newline at end of file