]> git.mxchange.org Git - mailer.git/blobdiff - inc/mysql-connect.php
Several more constants rewritten to getConfig()
[mailer.git] / inc / mysql-connect.php
index 697ad84610ca1c2470c97cf1b51ba562a6b077bb..3eac524730132966fe8dfc0741aa5cbe5c91daa7 100644 (file)
@@ -42,21 +42,12 @@ if (!defined('__SECURITY')) {
        require($INC);
 }
 
-// Non-database functions
-require('inc/functions.php');
-
-// Wrapper functions
-require('inc/wrapper-functions.php');
-
 // Load more function libraries or includes
-foreach (array('request-functions', 'session-functions', 'config-functions', 'code-functions', 'inc-functions', 'language-functions', 'filters', 'mysql-manager', 'extensions', 'handler', 'hooks') as $lib) {
+foreach (array('functions', 'request-functions', 'session-functions', 'code-functions', 'inc-functions', 'language-functions', 'filters', 'mysql-manager', 'extensions', 'handler', 'hooks') as $lib) {
        // Load special functions
        loadIncludeOnce('inc/' . $lib . '.php');
 } // END - foreach
 
-// Initialize the configuration
-initConfig();
-
 // Set error handler
 set_error_handler('__errorHandler');
 
@@ -182,10 +173,10 @@ if ((!isInstalling()) && (isInstalled())) {
                                // Is the extension sql_patches installed and at least 0.3.6?
                                if (GET_EXT_VERSION('sql_patches') >= '0.3.6') {
                                        // Generate random number
-                                       define('RAND_NUMBER', generateRandomCode(10, mt_rand(10000, 32766), getUserId(), ''));
+                                       setConfigEntry('RAND_NUMBER', generateRandomCode(10, mt_rand(10000, 32766), getUserId(), ''));
                                } else {
                                        // Generate weak (!!!) code
-                                       define('RAND_NUMBER', mt_rand(1000000, 9999999));
+                                       setConfigEntry('RAND_NUMBER', mt_rand(1000000, 9999999));
                                }
                        } else {
                                // Wrong database?