diff --git a/htdocs/install/check.php b/htdocs/install/check.php index e7aa7f4d302..97b645c5ec8 100644 --- a/htdocs/install/check.php +++ b/htdocs/install/check.php @@ -380,6 +380,7 @@ if (!file_exists($conffile)) { // Requirements met/all ok: display the next step button if ($checksok) { $ok = false; + $validfoundconf = false; // Try to create db connection if (file_exists($conffile)) { @@ -389,6 +390,8 @@ if (!file_exists($conffile)) { print 'A '.$conffiletoshow.' file exists with a dolibarr_main_document_root to '.$dolibarr_main_document_root.' that seems wrong. Try to fix or remove the '.$conffiletoshow.' file.
'."\n"; dol_syslog("A '".$conffiletoshow."' file exists with a dolibarr_main_document_root to ".$dolibarr_main_document_root." that seems wrong. Try to fix or remove the '".$conffiletoshow."' file.", LOG_WARNING); } else { + $validfoundconf = true; + require_once $dolibarr_main_document_root.'/core/lib/admin.lib.php'; // If password is encoded, we decode it @@ -444,6 +447,8 @@ if (!file_exists($conffile)) { // Version to install is DOL_VERSION $dolibarrlastupgradeversionarray = preg_split('/[\.-]/', getDolGlobalString('MAIN_VERSION_LAST_UPGRADE', getDolGlobalString('MAIN_VERSION_LAST_INSTALL'))); $dolibarrversiontoinstallarray = versiondolibarrarray(); + } elseif ($validfoundconf) { + print 'Failed to connect with data found int the current conf.php file.
'; } // Show title