HOR-4273 It is not possible to download the Support information in 'enterprise manager'

- Add method get server version
This commit is contained in:
Marco Antonio Nina Mena
2018-01-19 16:03:32 -04:00
parent 24a1d2d168
commit 4b8112e9ba
2 changed files with 23 additions and 6 deletions

View File

@@ -1291,5 +1291,25 @@ class System
throw $e;
}
}
/**
* Return version server software Apache/Nginx
*
* @return string version server software Apache/Nginx
*/
public static function getServerVersion()
{
$serverVersion = '';
if (stripos($_SERVER['SERVER_SOFTWARE'], 'apache') !== false) {
$serverVersion = apache_get_version();
}
if (stripos($_SERVER['SERVER_SOFTWARE'], 'nginx') !== false) {
$serverVersion = $_SERVER['SERVER_SOFTWARE'];
}
return $serverVersion;
}
}
// end System class