-use ['SERVER_SOFTWARE'] as the trick
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@3558 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
973fc09565
commit
5b89d29070
@ -873,11 +873,12 @@ function getGroups() {
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Returns true if we are running on AIX
|
||||
function isAIX() { if(exec("oslevel")) {return TRUE;}else {return FALSE;} } //todo: implement
|
||||
// use dirty trick
|
||||
function isAIX() { if($_SERVER["SERVER_SOFTWARE"] == "IBM_HTTP_Server") {return TRUE;}else {return FALSE;} } //todo: update to one elegant way later
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Returns true if we are running on Linux
|
||||
function isLinux() { if(exec("uname") == "Linux") {return TRUE;} else {return FALSE;} } //todo: implement
|
||||
function isLinux() { if(strstr($_SERVER["SERVER_SOFTWARE"], "Apache")==FALSE) {return FALSE;} else {return TRUE;} } //todo: update to one elegant way later
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Returns true if we are running on Windows
|
||||
|
Loading…
Reference in New Issue
Block a user