Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/erikdubbelboer/phpRedisAdmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErik Dubbelboer <erik@dubbelboer.com>2019-11-24 19:43:06 +0300
committerErik Dubbelboer <erik@dubbelboer.com>2019-11-24 19:43:06 +0300
commitc291de34a179faefa84ea53bee89176a5d380817 (patch)
tree994d2d5cae0ec6f0902952d215fd657e40450b00
parentfeed670bbdcb81b673de85f3327e0c232c915fd9 (diff)
Add showEmptyNamespaceAsKey and make <empty> grey
-rw-r--r--css/index.css4
-rw-r--r--includes/config.sample.inc.php1
-rw-r--r--index.php5
3 files changed, 10 insertions, 0 deletions
diff --git a/css/index.css b/css/index.css
index 80ceade..7b898e5 100644
--- a/css/index.css
+++ b/css/index.css
@@ -44,6 +44,10 @@ margin-top: .05em;
cursor: pointer;
}
+#keys li.empty a {
+color: #888;
+}
+
#keys li.current a {
background-color: #eee;
}
diff --git a/includes/config.sample.inc.php b/includes/config.sample.inc.php
index e24aa52..10ed201 100644
--- a/includes/config.sample.inc.php
+++ b/includes/config.sample.inc.php
@@ -38,6 +38,7 @@ $config = array(
'seperator' => ':',
+ 'showEmptyNamespaceAsKey' => false,
// Hide empty databases in the database list (global, valid for all servers unless set at server level)
'hideEmptyDBs' => false,
diff --git a/index.php b/index.php
index fc271b6..fa0c51e 100644
--- a/index.php
+++ b/index.php
@@ -34,6 +34,10 @@ if($redis) {
}
$key = explode($server['seperator'], $key);
+ if ($key[count($key) - 1] == '' && $config['showEmptyNamespaceAsKey']) {
+ array_pop($key);
+ $key[count($key) - 1] .= ':';
+ }
// $d will be a reference to the current namespace.
$d = &$namespaces;
@@ -98,6 +102,7 @@ if($redis) {
if (empty($name) && $name != '0') {
$name = '<empty>';
+ $class[] = 'empty';
}
?>