Update install.php

Verify if server has SERVER_SOFTWARE defined. If the variable isn't defined it still doesn't make sense to ask for the .htaccess as it definitively isn't Apache or LiteSpeed (or is a very strange self compiled version of those softwares).
This commit is contained in:
Alexandre Teles 2016-08-24 18:15:39 -03:00 committed by GitHub
parent eb3d5955de
commit f5a987b91f
1 changed files with 1 additions and 1 deletions

View File

@ -190,7 +190,7 @@ function checkSystem()
$phpModules = get_loaded_extensions(); $phpModules = get_loaded_extensions();
} }
if ((stripos($_SERVER['SERVER_SOFTWARE'], 'Apache') !== false || stripos($_SERVER['SERVER_SOFTWARE'], 'LiteSpeed') !== false) && !file_exists(PATH_ROOT.'.htaccess')) { if (array_key_exists('SERVER_SOFTWARE', $_SERVER) && ((stripos($_SERVER['SERVER_SOFTWARE'], 'Apache') !== false || stripos($_SERVER['SERVER_SOFTWARE'], 'LiteSpeed') !== false) && !file_exists(PATH_ROOT.'.htaccess'))) {
$errorText = 'Missing file, upload the file .htaccess (ERR_201)'; $errorText = 'Missing file, upload the file .htaccess (ERR_201)';
error_log($errorText, 0); error_log($errorText, 0);