]> git.mxchange.org Git - mailer.git/commitdiff
Fix for the fix... ;-)
authorRoland Häder <roland@mxchange.org>
Sun, 21 Sep 2008 14:39:41 +0000 (14:39 +0000)
committerRoland Häder <roland@mxchange.org>
Sun, 21 Sep 2008 14:39:41 +0000 (14:39 +0000)
18 files changed:
admin.php
agb.php
beg.php
birthday_confirm.php
doubler.php
img.php
inc/databases.php
inc/functions.php
inc/mysql-connect.php
index.php
lead-confirm.php
login.php
mailid.php
mailid_top.php
ref.php
show_bonus.php
sponsor_confirm.php
surfbar.php

index f73daff9086a152e9fb56ffc18ec297748ce9a27..5c6f49d107b058e58c25e1eae78fcbffb31d2797 100644 (file)
--- a/admin.php
+++ b/admin.php
@@ -45,7 +45,7 @@ $GLOBALS['module'] = "admin"; $CSS = -1;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Simply redirect... :-)
        LOAD_URL("modules.php?module=admin&amp;action=login");
diff --git a/agb.php b/agb.php
index c9c2654fc8c2c8320478de57cdc57b307ef10c62..3302830217ec27d74238b7f82bf89443b005b406 100644 (file)
--- a/agb.php
+++ b/agb.php
@@ -45,7 +45,7 @@ $GLOBALS['module'] = "agb"; $CSS = -1;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Simply redirect... :-)
        LOAD_URL("modules.php?module=index&amp;what=agb");
diff --git a/beg.php b/beg.php
index a7564ce67cf720227a91989481adcd7643808cb6..f4a0bd13f3aba0935318e6d761095b764f60036b 100644 (file)
--- a/beg.php
+++ b/beg.php
@@ -49,7 +49,7 @@ $msg = null;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Check for userid
        if (!empty($_GET['uid'])) {
                // Init user ID
index b9b4242e5a043526530ab0ce4f81cf1eb6e234dc..4d2b0058cebd4f6e591f7b13d35f786e14ebee6a 100644 (file)
@@ -45,7 +45,7 @@ $GLOBALS['module'] = "birthday_confirm"; $CSS = -1;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Script is installed so let's check for his confirmation link...
        $uid = bigintval($_GET['uid']);
 
index eab1a6d5335985ee2cc2864e6467bcfec461523e..87f177fc6e0f1b53fbf5c3ebc9e19f423f88cef7 100644 (file)
@@ -48,7 +48,7 @@ $CSS = 0;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Probe for referral ID
        if (!empty($_GET['refid'])) $GLOBALS['refid'] = bigintval($_GET['refid']);
diff --git a/img.php b/img.php
index 8710bd0ba13a908deb43f2d398fa250c59e83645..df3c72506b67ed34b7494a3a4f5beea5ac3e1bc2 100644 (file)
--- a/img.php
+++ b/img.php
@@ -44,7 +44,7 @@ $GLOBALS['module'] = "img"; $CSS = -1;
 // Load the required file(s)
 require ("inc/config.php");
 
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        if (!empty($_GET['code']))
        {
index 1bbe2a3293a207d1345d8cf7692b7efa89f17598..7bac8788d111d97d3df219e1aa07637398c9cfdb 100644 (file)
@@ -113,7 +113,7 @@ define('USAGE_BASE', "usage");
 define('SERVER_URL', "http://www.mxchange.org");
 
 // This current patch level
-define('CURR_SVN_REVISION', "377");
+define('CURR_SVN_REVISION', "378");
 
 // Take a prime number which is long (if you know a longer one please try it out!)
 define('_PRIME', 591623);
index 318af2c2262240efe73ee8b02eeda1682c680d58..b888b2779f474ac59860e01cd8ba69ad48b8ee9d 100644 (file)
@@ -903,7 +903,7 @@ function LOAD_URL($URL, $addUrlData=true) {
                print("<pre>");
                debug_print_backtrace();
                die("</pre>URL={$URL}");
-               /**/
+               */
                @header ("Location: ".str_replace("&amp;", "&", $URL));
        } else {
                // Output error message
@@ -2227,14 +2227,17 @@ function isBooleanConstantAndTrue($constName) { // : Boolean
        // In cache?
        if (isset($constCache[$constName])) {
                // Use cache
+               //* DEBUG: */ echo __FUNCTION__.": ".$constName."-CACHE!<br />\n";
                $res = $constCache[$constName];
        } else {
                // Check constant
+               //* DEBUG: */ echo __FUNCTION__.": ".$constName."-RESOLVE!<br />\n";
                if (defined($constName)) $res = (constant($constName) === true);
 
                // Set cache
                $constCache[$constName] = $res;
        }
+       //* DEBUG: */ var_dump($res);
 
        // Return value
        return $res;
index 600eae105304340a7a8d000062b7b800f14500f8..467f21827a2b8a918da9294fed70edaf8eb94ba9 100644 (file)
@@ -49,6 +49,11 @@ require_once(PATH."inc/db/lib.php");
 
 // Load general functions
 require_once(PATH."inc/functions.php");  // Non-database functions
+
+// Load more include files
+require_once(PATH."inc/mysql-manager.php"); // Functions which interact with the database
+
+// Load extensions and language
 require_once(PATH."inc/extensions.php");
 require_once(PATH."inc/language.php");
 
@@ -69,7 +74,7 @@ if ((empty($MySQL['login'])) && (!defined('mxchange_installing')) && (!isset($_G
 }
 
 // Check if this file is writeable or read-only and warn the user
-if ((!defined('mxchange_installing')) && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if ((!isBooleanConstantAndTrue('mxchange_installing')) && (isBooleanConstantAndTrue('mxchange_installed'))) {
        // Check for write-permission for config.php and inc directory
        if (empty($GLOBALS['module'])) $GLOBALS['module'] = "index";
        if (($GLOBALS['module'] != "admin") && (isBooleanConstantAndTrue('admin_registered')) && (!isset($_SERVER['WINDIR']))) {
@@ -91,9 +96,6 @@ if ((!defined('mxchange_installing')) && (isBooleanConstantAndTrue('mxchange_ins
 
                        // Is it a valid resource?
                        if ($db === true) {
-                               // Load more include files
-                               require_once(PATH."inc/mysql-manager.php"); // Functions which interact with the database
-
                                // Load configuration stuff
                                $_CONFIG = LOAD_CONFIG();
 
index 1af40fcdb50e6a8bed06c5538e6f04798266efb6..5a4e26340be790fbc6d16605fc6ad958683b6410 100644 (file)
--- a/index.php
+++ b/index.php
@@ -46,7 +46,7 @@ $GLOBALS['module'] = "index";
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Header
        require(PATH."inc/header.php");
 
index 5c806993e114fe18f3b41b2989beee16d7b10cd6..0f62cef8d79b88088c43a879977cb3383e25d572 100644 (file)
@@ -46,7 +46,7 @@ $GLOBALS['module'] = "lead-confirm";
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Header
        require(PATH."inc/header.php");
 
index 4fb124e6071202bafe77f80b78ac19105984a9f6..e0e72b32ac94b32691e433821151b1643a83baeb 100644 (file)
--- a/login.php
+++ b/login.php
@@ -45,7 +45,7 @@ $GLOBALS['module'] = "login";
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Simply redirect... :-)
        LOAD_URL("modules.php?module=index&amp;what=login");
index d530bb2a3b839450f3dae768a6aa55562f21a99d..09b03ff3831477d70e5e0845e9e86e19c967a4be 100644 (file)
@@ -44,7 +44,7 @@ $GLOBALS['module'] = "mailid"; $CSS = -1;
 // Load the required file(s)
 require ("inc/config.php");
 
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Is the extension active
        if (!EXT_IS_ACTIVE("mailid", true)) {
index 0c54c6fc9bf20312f3244cb02962932e897da64e..f2829ac315747378c7ca9d3a050d83a7eec579b6 100644 (file)
@@ -44,7 +44,7 @@ $GLOBALS['module'] = "mailid";  $CSS = 0;
 // Load the required file(s)
 require ("inc/config.php");
 
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Is the extension active
        if (!EXT_IS_ACTIVE("mailid", true)) {
diff --git a/ref.php b/ref.php
index dbbff4b257a41a5bf132fc18bb861edfa7f30d43..e6e51d7b83f32eb87eb95da143a01c512d6ed557 100644 (file)
--- a/ref.php
+++ b/ref.php
@@ -45,7 +45,7 @@ $GLOBALS['module'] = "ref"; $CSS = -1;
 require ("inc/config.php");
 
 // Redirect only to registration page when this script is installed
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Base URL for redirection
        switch ($_CONFIG['refid_target'])
        {
index 6ac941f49fd1da50b97a583c7b1cf4ef9ee209bc..45019b90f62f869f5f18aabb8397c099f5dd2f7c 100644 (file)
@@ -46,7 +46,7 @@ $GLOBALS['module'] = "show_bonus"; $CSS = 0;
 require ("inc/config.php");
 
 // List only rankings when script is installed
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed')))
+if (isBooleanConstantAndTrue('mxchange_installed'))
 {
        // Include header
        include(PATH."inc/header.php");
index 85cbbf61c9429d276c0cd64bc839beb496fa93a9..c10f2cef31c8518f0b37f3f7a86d08db2e27e11f 100644 (file)
@@ -37,7 +37,7 @@ require_once("inc/libs/security_functions.php");
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Base URL for redirection
        $URL = URL."/modules.php?module=index&amp;what=sponsor_login&hash=";
        if (empty($_GET['hash'])) {
index 57372bdd693528495851c38544792bffcad888d6..93510abffa06ab1e94dddec7f5675b5992cd5684 100644 (file)
@@ -50,7 +50,7 @@ $msg = null;
 require ("inc/config.php");
 
 // Is the script installed?
-if (defined('mxchange_installed') && (isBooleanConstantAndTrue('mxchange_installed'))) {
+if (isBooleanConstantAndTrue('mxchange_installed')) {
        // Only logged in users may use this surfbar!
        if (!IS_MEMBER()) {
                // Redirect