]> git.mxchange.org Git - mailer.git/blobdiff - inc/config-functions.php
New naming convention applied to many functions, see #118 for details
[mailer.git] / inc / config-functions.php
index 66ae2e02f620be1ca36c95fbf5f12100ea948bc6..186ede833979629932d5b0994eec5780746665a1 100644 (file)
@@ -38,7 +38,7 @@
 
 // Some security stuff...
 if (!defined('__SECURITY')) {
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4)."/security.php";
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), '/inc') + 4) . '/security.php';
        require($INC);
 }
 
@@ -115,7 +115,7 @@ function initConfig () {
 }
 
 // Load configuration and return it as an arry
-function loadConfiguration ($no="0") {
+function loadConfiguration ($no = '0') {
        global $_CONFIG;
 
        // Check for cache extension, cache-array and if the requested configuration is in cache
@@ -127,10 +127,10 @@ function loadConfiguration ($no="0") {
                } // END - foreach
 
                // Count cache hits if exists
-               if ((isset($_CONFIG['cache_hits'])) && (EXT_IS_ACTIVE("cache"))) {
+               if ((isset($_CONFIG['cache_hits'])) && (EXT_IS_ACTIVE('cache'))) {
                        $_CONFIG['cache_hits']++;
                } // END - if
-       } elseif ((!EXT_IS_ACTIVE("cache")) || (!isset($GLOBALS['cache_array']['config'][$no]))) {
+       } elseif ((!EXT_IS_ACTIVE('cache')) || (!isset($GLOBALS['cache_array']['config'][$no]))) {
                // Load config from DB
                $result_config = SQL_QUERY_ESC("SELECT * FROM `{!_MYSQL_PREFIX!}_config` WHERE config=%d LIMIT 1",
                        array(bigintval($no)), __FUNCTION__, __LINE__);