More places rewritten to use incrementConfigEntry()
authorRoland Häder <roland@mxchange.org>
Sat, 20 Dec 2008 11:01:47 +0000 (11:01 +0000)
committerRoland Häder <roland@mxchange.org>
Sat, 20 Dec 2008 11:01:47 +0000 (11:01 +0000)
doubler.php
inc/databases.php
inc/db/lib-mysql3.php
inc/functions.php

index 333467c..d002ed7 100644 (file)
@@ -159,7 +159,7 @@ if (isBooleanConstantAndTrue('mxchange_installed')) {
 
                                        // Update usage counter
                                        UPDATE_CONFIG("doubler_counter", 1, "+");
-                                       $_CONFIG['doubler_counter']++;
+                                       incrementCondigEntry('doubler_counter');
 
                                        // Set constant
                                        define('__DOUBLER_MSG', LOAD_TEMPLATE("doubler_reflink", true, $_POST['userid']));
index 62ecf0d..152df98 100644 (file)
@@ -115,7 +115,7 @@ define('USAGE_BASE', "usage");
 define('SERVER_URL', "http://www.mxchange.org");
 
 // Current SVN revision
-define('CURR_SVN_REVISION', "690");
+define('CURR_SVN_REVISION', "691");
 
 // Take a prime number which is long (if you know a longer one please try it out!)
 define('_PRIME', 591623);
index 3d7f11c..fe37cb6 100644 (file)
@@ -64,8 +64,7 @@ Query string:<br />
        $_CONFIG['db_last_query'] = $sql_string;
 
        // Count this query
-       if (getConfig('sql_count') == null) $_CONFIG['sql_count'] = 0;
-       $_CONFIG['sql_count']++;
+       incrementConfigEntry('sql_count');
 
        // Debug output
        //* DEBUG: */ print "Query=<pre>".$sql_string."</pre>, affected=<b>".SQL_AFFECTEDROWS()."</b>, numrows=<b>".SQL_NUMROWS($result)."</b><br />\n";
index d26f28d..0ef88af 100644 (file)
@@ -233,11 +233,7 @@ function LOAD_TEMPLATE($template, $return=false, $content=array()) {
        $template = strtolower($template);
 
        // Count the template load
-       if (getConfig('num_templates') == null) {
-               $_CONFIG['num_templates'] = 1;
-       } else {
-               $_CONFIG['num_templates']++;
-       }
+       incrementConfigEntry('num_templates');
 
        // Prepare IP number and User Agent
        $REMOTE_ADDR     = GET_REMOTE_ADDR();