mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2025-12-30 00:53:50 +00:00
Update system_information array with apcu_enable and hostname
This commit is contained in:
@@ -84,7 +84,7 @@
|
|||||||
|
|
||||||
//system information
|
//system information
|
||||||
function system_information(): array {
|
function system_information(): array {
|
||||||
global $db_type;
|
global $database, $db_type;
|
||||||
$system_information = [];
|
$system_information = [];
|
||||||
$esl = event_socket::create();
|
$esl = event_socket::create();
|
||||||
|
|
||||||
@@ -148,6 +148,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
$system_information['php']['version'] = phpversion();
|
$system_information['php']['version'] = phpversion();
|
||||||
|
$system_information['php']['apcu'] = (function_exists('apcu_enabled') && apcu_enabled()) ? 'true' : 'false';
|
||||||
|
|
||||||
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
|
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
|
||||||
$data = explode("\n", shell_exec('systeminfo /FO CSV 2> nul'));
|
$data = explode("\n", shell_exec('systeminfo /FO CSV 2> nul'));
|
||||||
@@ -180,6 +181,7 @@
|
|||||||
$system_information['os']['version'] = 'permission denied';
|
$system_information['os']['version'] = 'permission denied';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$system_information['os']['hostname'] = gethostname();
|
||||||
$system_information['os']['date'] = date('r');
|
$system_information['os']['date'] = date('r');
|
||||||
$system_information['os']['type'] = PHP_OS;
|
$system_information['os']['type'] = PHP_OS;
|
||||||
|
|
||||||
@@ -272,7 +274,6 @@
|
|||||||
|
|
||||||
//database version
|
//database version
|
||||||
$sql = "select version(); ";
|
$sql = "select version(); ";
|
||||||
$database = new database;
|
|
||||||
$database_name = $database->select($sql, null, 'column');
|
$database_name = $database->select($sql, null, 'column');
|
||||||
$database_array = explode(' ', $database_name);
|
$database_array = explode(' ', $database_name);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user