',$license); } return $license; } function GetServerProtocol() { if(isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') { return 'https://'; } else { $protocol = preg_replace('/^([a-z]+)\/.*$/', '\\1', strtolower($_SERVER['SERVER_PROTOCOL'])); $protocol .= '://'; return $protocol; } } function GetServerURL() { return GetServerProtocol().$_SERVER['HTTP_HOST'].dirname($_SERVER['PHP_SELF']); } function GetBaseDir() { $pathParts = pathinfo($_SERVER['SCRIPT_FILENAME']); $basedirPath = $pathParts['dirname']; return $basedirPath; } ?>