Rewritten to function getConfigArray()
authorRoland Häder <roland@mxchange.org>
Fri, 13 Mar 2009 03:11:40 +0000 (03:11 +0000)
committerRoland Häder <roland@mxchange.org>
Fri, 13 Mar 2009 03:11:40 +0000 (03:11 +0000)
inc/config-functions.php
inc/functions.php

index 3358a302a9eedee88469c92e1048188bb11f233b..66ae2e02f620be1ca36c95fbf5f12100ea948bc6 100644 (file)
@@ -149,5 +149,13 @@ function loadConfiguration ($no="0") {
        }
 }
 
+// Getter for whole $_CONFIG array
+function getConfigArray () {
+       global $_CONFIG;
+
+       // Return it
+       return $_CONFIG;
+}
+
 // [EOF]
 ?>
index e202db15d3e7750537b78684bf6b0ae533f3c5be..8ae2ab07d0ee3797abdb55f3403b84807867f788 100644 (file)
@@ -211,7 +211,10 @@ function getTotalFatalErrors () {
 // Load a template file and return it's content (only it's name; do not use ' or ")
 function LOAD_TEMPLATE ($template, $return=false, $content=array()) {
        // Add more variables which you want to use in your template files
-       global $DATA, $_CONFIG, $username;
+       global $DATA, $username;
+
+       // Get whole config array
+       $_CONFIG = getConfigArray();
 
        // Make all template names lowercase
        $template = strtolower($template);