From 57393eb9cf461f190998bf442b19b57e7b5d4343 Mon Sep 17 00:00:00 2001 From: enriquecd Date: Fri, 19 May 2017 11:12:58 +0200 Subject: [PATCH] Fix logout bad permission with myslq service stopped dialog - #825 --- pandora_console/index.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pandora_console/index.php b/pandora_console/index.php index 41939787b6..6153b5ae6c 100755 --- a/pandora_console/index.php +++ b/pandora_console/index.php @@ -33,6 +33,8 @@ if ($develop_bypass != 1) { $config['homeurl'] = $_SERVER['REQUEST_URI']; $config['homeurl_static'] = $_SERVER['REQUEST_URI']; + + require('general/error_screen.php'); exit; } @@ -65,12 +67,12 @@ if ($develop_bypass != 1) { if ((substr (sprintf ('%o', fileperms('include/config.php')), -4) != "0600") && (substr (sprintf ('%o', fileperms('include/config.php')), -4) != "0660") && (substr (sprintf ('%o', fileperms('include/config.php')), -4) != "0640")) { - $ownDir = dirname(__FILE__) . DIRECTORY_SEPARATOR; + $ownDir = dirname(__FILE__) . DIRECTORY_SEPARATOR; + $url = explode('/', $_SERVER['REQUEST_URI']); $config['homedir'] = $ownDir; - $config['homeurl'] = $_SERVER['REQUEST_URI']; - $config['homeurl_static'] = $_SERVER['REQUEST_URI']; + $config['homeurl'] = "/" . $url[1]; + $config['homeurl_static'] = "/" . $url[1]; $login_screen = 'error_perms'; - require('general/error_screen.php'); exit; }