]> git.mxchange.org Git - mailer.git/blobdiff - inc/install-inc.php
Some functions rewritten to hungarian notation, handling of array rewritten
[mailer.git] / inc / install-inc.php
index 0ff9df89976b9622efd1dc1f383e5d52cd463eae..1b9ecb61af12783a006787fc589f3350f5034292 100644 (file)
@@ -164,7 +164,7 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
                if (empty($mysql['login']))  $mysql['login']  = "your_login";
                if (empty($mysql['host']))   $mysql['host']   = "localhost";
                if (empty($mysql['prefix'])) $mysql['prefix'] = "mxchange_";
-               if ((sizeof($FATAL) > 0) || (!empty($FATAL[0]))) {
+               if (getTotalFatalErrors() > 0) {
                        OUTPUT_HTML("<SPAN class=\"install_fatal\">");
                        foreach ($FATAL as $key => $err) {
                                OUTPUT_HTML("  <STRONG>&middot;</STRONG>&nbsp;".FATAL_NO.($key + 1).":&nbsp;".$err."<br />");
@@ -333,7 +333,7 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
        case "finalize": // Write captured data to files
                if ((!empty($_POST['finalize'])) && (!isBooleanConstantAndTrue('mxchange_installed'))) {
                        // You have submitted data then we have to reset the fatal messages
-                       $FATAL = array(); $SQLs = array();
+                       $SQLs = array();
 
                        // Connect to MySQL server
                        $link = SQL_CONNECT($mysql['host'], $mysql['login'], $mysql['pass1'], __FILE__, __LINE__);
@@ -359,7 +359,7 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
                                                // Are some SQLs found?
                                                if (count($SQLs) == 0) {
                                                        // Abort here
-                                                       ADD_FATAL(INSTALL_SQL_IMPORT_FAILED);
+                                                       addFatalMessage(INSTALL_SQL_IMPORT_FAILED);
                                                        return;
                                                } // END - if
 
@@ -396,12 +396,12 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
                                                install_WriteData($_POST['spath']."inc/config.php", "INSTALLED", "define('mxchange_installed', ", ");", "true", 0);
                                        } else {
                                                // Installation area not found!
-                                               ADD_FATAL(INSTALL_MISSING_DUMPS);
+                                               addFatalMessage(INSTALL_MISSING_DUMPS);
                                        }
                                } // END - if
                        } // END - if
 
-                       if ((sizeof($FATAL) > 0) || ((isset($FATAL[0])) && ($FATAL[0] != ''))) {
+                       if (getTotalFatalErrors() > 0) {
                                $OUT = "";
                                foreach ($FATAL as $value) {
                                        $OUT .= "    <LI>".$value."</LI>\n";
@@ -455,7 +455,7 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
                        LOAD_TEMPLATE("install_finished");
                } else {
                        // Something goes wrong during installation! :-(
-                       ADD_FATAL(INSTALL_FINALIZER_FAILED);
+                       addFatalMessage(INSTALL_FINALIZER_FAILED);
                        include ("inc/fatal_errors.php");
                }
                break;
@@ -466,7 +466,7 @@ if ((!isBooleanConstantAndTrue('mxchange_installed')) || (!isBooleanConstantAndT
                break;
        }
 } else {
-       ADD_FATAL(ALREADY_INSTALLED);
+       addFatalMessage(ALREADY_INSTALLED);
 }
 //
 ?>