From 756c4016130bb63a88e2eed07740d98fa5538a00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vo=C5=99=C3=AD=C5=A1ek?= Date: Fri, 10 Jan 2020 09:39:02 +0100 Subject: [PATCH 01/59] Remove usage of get_magic_quotes_gpc method (#158) --- includes/common.inc.php | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/includes/common.inc.php b/includes/common.inc.php index ca63814..85dfe76 100644 --- a/includes/common.inc.php +++ b/includes/common.inc.php @@ -3,26 +3,6 @@ define('PHPREDIS_ADMIN_PATH', dirname(__DIR__)); -// Undo magic quotes (both in keys and values) -if (function_exists('get_magic_quotes_gpc') && get_magic_quotes_gpc()) { - $process = array(&$_GET, &$_POST); - - foreach ($process as $key => $val) { - foreach ($val as $k => $v) { - unset($process[$key][$k]); - - if (is_array($v)) { - $process[$key][stripslashes($k)] = $v; - $process[] = &$process[$key][stripslashes($k)]; - } else { - $process[$key][stripslashes($k)] = stripslashes($v); - } - } - } - - unset($process); -} - From 7e4bc6cfedc02e045ef43936d615e07444c0de07 Mon Sep 17 00:00:00 2001 From: Erik Dubbelboer Date: Fri, 10 Jan 2020 08:48:08 +0000 Subject: [PATCH 02/59] v1.12.0 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 7d6cb26..7198e92 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "erik-dubbelboer/php-redis-admin", "description": "Simple web interface to manage Redis databases.", - "version": "1.11.5", + "version": "1.12.0", "license": "CC-BY-3.0", "homepage": "https://github.com/ErikDubbelboer/phpRedisAdmin", "authors": [ From 5752c5087023464e8f41161e77a87c3a8263ac95 Mon Sep 17 00:00:00 2001 From: Alex Stansfield Date: Sat, 1 Feb 2020 04:19:00 +0700 Subject: [PATCH 03/59] Allow 'databases' server config option to be set by ENV (#159) This is quite specific to my needs, but possibly useful for others. My setup is PhpRedisAdmin running in Docker on ECS Fargate connnecting to Redis Elasticache. AWS Elasticache has a restricted CONFIG command so you can't get the databases. This change allows me to set the databases in the Task Definition in ECS. --- includes/config.environment.inc.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/includes/config.environment.inc.php b/includes/config.environment.inc.php index 0522421..587899c 100644 --- a/includes/config.environment.inc.php +++ b/includes/config.environment.inc.php @@ -24,6 +24,7 @@ $server_host = getenv($prefix . 'HOST'); $server_port = getenv($prefix . 'PORT'); $server_auth = getenv($prefix . 'AUTH'); + $server_databases = getenv($prefix . 'DATABASES'); if (empty($server_host)) { break; @@ -51,6 +52,10 @@ if (!empty($server_auth)) { $config['servers'][$i-1]['auth'] = $server_auth; } + + if (!empty($server_databases)) { + $config['servers'][$i-1]['databases'] = $server_databases; + } $i++; } From 9eb60157dc13e660d6707af40835b8227b2ae3e9 Mon Sep 17 00:00:00 2001 From: Erik Dubbelboer Date: Fri, 31 Jan 2020 20:53:00 +0000 Subject: [PATCH 04/59] v1.13.0 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 7198e92..0cfdc77 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "erik-dubbelboer/php-redis-admin", "description": "Simple web interface to manage Redis databases.", - "version": "1.12.0", + "version": "1.13.0", "license": "CC-BY-3.0", "homepage": "https://github.com/ErikDubbelboer/phpRedisAdmin", "authors": [ From 4501c5d6500a926784fa32e7607065526f85e556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Abra=C3=A3o=20Zaidan?= Date: Fri, 28 Feb 2020 10:24:17 -0300 Subject: [PATCH 05/59] Avoid unnecessary horizontal scrollbars (#160) * Avoid unnecessary horizontal scrollbars Fix long key values rendering with horizontal scrollbar; Fix keys folder with checkbox in one line and key name in another line. * Ellipsis replaced by horizontal scrollbar while keeping elements aligned https://github.com/erikdubbelboer/phpRedisAdmin/pull/160#issuecomment-589968360 * Fix missing padding on the right frame in Firefox for Mac https://github.com/erikdubbelboer/phpRedisAdmin/pull/160#issuecomment-590048242 --- css/common.css | 2 +- css/index.css | 15 ++++++++++++--- index.php | 5 +++-- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/css/common.css b/css/common.css index b2a8431..9dc6276 100644 --- a/css/common.css +++ b/css/common.css @@ -52,6 +52,6 @@ background: url(http://github.com/images/add.png) left center no-repeat; .data { -white-space: pre; +white-space: pre-wrap; } diff --git a/css/index.css b/css/index.css index 7b898e5..4a56aa9 100644 --- a/css/index.css +++ b/css/index.css @@ -3,10 +3,14 @@ position: absolute; top: 0; bottom: 0; left: 0; +display: flex; +flex-direction: column; width: 290px; height: 100%; +} + +#header { padding-left: 10px; -border-right: 1px solid #000; } #sidebar a, #sidebar a:visited { @@ -23,7 +27,9 @@ text-decoration: underline; #keys { +flex-grow: 1; width: 290px; +margin-top: 10px; padding-left: 10px; overflow: auto; } @@ -36,6 +42,7 @@ padding: 0; #keys li { font-weight: normal; +white-space: nowrap; } #keys li.folder { @@ -115,6 +122,7 @@ background-color: #aaa; cursor: col-resize; padding: 0; margin: 0; +border-left: 1px solid #000; } #resize-layover { @@ -133,11 +141,12 @@ top: 0; left: 305px; right: 0; bottom: 0; -padding-left: 2em; } #frame iframe { -width: 100%; +width: calc(100% - 3em); height: 100%; +margin-left: 1.5em; +margin-right: 1.5em; } diff --git a/index.php b/index.php index 5ea3b25..933796a 100644 --- a/index.php +++ b/index.php @@ -108,7 +108,7 @@ function print_namespace($item, $name, $fullkey, $islast) { ?> > - () + ()