@@ -62,7 +62,7 @@ if ($action == 'delete' && function_exists('apcu_clear_cache') && $userinfo['cha
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!function_exists('apcu_cache_info') || !function_exists('apcu_sma_info')) {
|
if (!function_exists('apcu_cache_info') || !function_exists('apcu_sma_info')) {
|
||||||
Response::standardError(lng('error.no_apcuinfo'));
|
Response::standardError('no_apcuinfo');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($page == 'showinfo' && $userinfo['change_serversettings'] == '1') {
|
if ($page == 'showinfo' && $userinfo['change_serversettings'] == '1') {
|
||||||
|
|||||||
@@ -58,12 +58,12 @@ if ($action == 'reset' && function_exists('opcache_reset') && $userinfo['change_
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!extension_loaded('Zend OPcache')) {
|
if (!extension_loaded('Zend OPcache')) {
|
||||||
Response::standardError(lng('error.no_opcacheinfo'));
|
Response::standardError('no_opcacheinfo');
|
||||||
}
|
}
|
||||||
|
|
||||||
$ocEnabled = ini_get('opcache.enable');
|
$ocEnabled = ini_get('opcache.enable');
|
||||||
if (empty($ocEnabled)) {
|
if (empty($ocEnabled)) {
|
||||||
Response::standardError(lng('error.inactive_opcacheinfo'));
|
Response::standardError('inactive_opcacheinfo');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($page == 'showinfo' && $userinfo['change_serversettings'] == '1') {
|
if ($page == 'showinfo' && $userinfo['change_serversettings'] == '1') {
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ if ($page == 'overview' && $userinfo['change_serversettings'] == '1') {
|
|||||||
|
|
||||||
// check if the session timeout is too low #815
|
// check if the session timeout is too low #815
|
||||||
if (isset($_POST['session_sessiontimeout']) && $_POST['session_sessiontimeout'] < 60) {
|
if (isset($_POST['session_sessiontimeout']) && $_POST['session_sessiontimeout'] < 60) {
|
||||||
Response::standardError(lng('error.session_timeout'), lng('error.session_timeout_desc'));
|
Response::standardError(['session_timeout', 'session_timeout_desc']);
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@@ -132,7 +132,7 @@ if ($page == 'overview' && $userinfo['change_serversettings'] == '1') {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
Response::standardError(lng('error.no_phpinfo'));
|
Response::standardError('error.no_phpinfo');
|
||||||
}
|
}
|
||||||
UI::view('settings/phpinfo.html.twig', [
|
UI::view('settings/phpinfo.html.twig', [
|
||||||
'phpversion' => PHP_VERSION,
|
'phpversion' => PHP_VERSION,
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ class Response
|
|||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sends an header ( 'Location ...' ) to the browser.
|
* Sends a header ( 'Location ...' ) to the browser.
|
||||||
*
|
*
|
||||||
* @param string $destination
|
* @param string $destination
|
||||||
* Destination
|
* Destination
|
||||||
@@ -74,18 +74,18 @@ class Response
|
|||||||
$linker->filename = $path . $destination;
|
$linker->filename = $path . $destination;
|
||||||
}
|
}
|
||||||
header('Location: ' . $linker->getLink());
|
header('Location: ' . $linker->getLink());
|
||||||
exit();
|
exit;
|
||||||
} elseif ($get_variables == null) {
|
} elseif ($get_variables == null) {
|
||||||
$linker = new Linker($destination);
|
$linker = new Linker($destination);
|
||||||
header('Location: ' . $linker->getLink());
|
header('Location: ' . $linker->getLink());
|
||||||
exit();
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prints one ore more errormessages on screen
|
* Prints one or more errormessages on screen
|
||||||
*
|
*
|
||||||
* @param array $errors
|
* @param array $errors
|
||||||
* Errormessages
|
* Errormessages
|
||||||
@@ -93,8 +93,9 @@ class Response
|
|||||||
* A %s in the errormessage will be replaced by this string.
|
* A %s in the errormessage will be replaced by this string.
|
||||||
* @param bool $throw_exception
|
* @param bool $throw_exception
|
||||||
*
|
*
|
||||||
* @author Florian Lippert <flo@syscp.org> (2003-2009)
|
* @throws Exception
|
||||||
* @author Ron Brand <ron.brand@web.de>
|
* @author Ron Brand <ron.brand@web.de>
|
||||||
|
* @author Florian Lippert <flo@syscp.org> (2003-2009)
|
||||||
*/
|
*/
|
||||||
public static function standardError($errors = '', $replacer = '', $throw_exception = false)
|
public static function standardError($errors = '', $replacer = '', $throw_exception = false)
|
||||||
{
|
{
|
||||||
@@ -157,7 +158,7 @@ class Response
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prints one ore more errormessages on screen
|
* Prints one or more errormessages on screen
|
||||||
*
|
*
|
||||||
* @param array $success_message
|
* @param array $success_message
|
||||||
* Errormessages
|
* Errormessages
|
||||||
@@ -166,6 +167,7 @@ class Response
|
|||||||
* @param array $params
|
* @param array $params
|
||||||
* @param bool $throw_exception
|
* @param bool $throw_exception
|
||||||
*
|
*
|
||||||
|
* @throws Exception
|
||||||
* @author Florian Lippert <flo@syscp.org> (2003-2009)
|
* @author Florian Lippert <flo@syscp.org> (2003-2009)
|
||||||
*/
|
*/
|
||||||
public static function standardSuccess($success_message = '', $replacer = '', $params = [], $throw_exception = false)
|
public static function standardSuccess($success_message = '', $replacer = '', $params = [], $throw_exception = false)
|
||||||
|
|||||||
Reference in New Issue
Block a user