]> git.mxchange.org Git - mailer.git/blobdiff - doubler.php
Don't use convertZeroToNull() here as it makes no sense
[mailer.git] / doubler.php
index 80b913e61e74076483032284995e540f7d39e943..d8a7f4be5643c34eb776dd564a69c00bcd952b91 100644 (file)
@@ -16,7 +16,7 @@
  * $Author::                                                          $ *
  * -------------------------------------------------------------------- *
  * Copyright (c) 2003 - 2009 by Roland Haeder                           *
- * Copyright (c) 2009 - 2011 by Mailer Developer Team                   *
+ * Copyright (c) 2009 - 2012 by Mailer Developer Team                   *
  * For more information visit: http://mxchange.org                      *
  *                                                                      *
  * This program is free software; you can redistribute it and/or modify *
 require('inc/libs/security_functions.php');
 
 // Init start time
-$GLOBALS['startTime'] = microtime(true);
+$GLOBALS['__start_time'] = microtime(true);
 
-// Set module
-$GLOBALS['module'] = 'doubler';
-$GLOBALS['output_mode'] = '0';
+// Set module and output mode
+$GLOBALS['__module']      = 'doubler';
+$GLOBALS['__output_mode'] = '0';
 
 // Load the required file(s)
 require('inc/config-global.php');
@@ -102,7 +102,7 @@ if (isFormSent()) {
                                SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_doubler` (`userid`,`refid`,`points`,`remote_ip`,`timemark`,`completed`,`is_ref`) VALUES (%s,%s,%s,'%s', UNIX_TIMESTAMP(), 'N','N')",
                                        array(
                                                getUserData('userid'),
-                                               makeZeroToNull(determineReferralId()),
+                                               convertZeroToNull(determineReferralId()),
                                                bigintval(postRequestElement('points') * 2),
                                                detectRemoteAddr()
                                        ), __FILE__, __LINE__);
@@ -120,7 +120,7 @@ if (isFormSent()) {
                                        // Okay add a refid line and apply refid percents
                                        SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_doubler` (`userid`,`refid`,`points`,`remote_ip`,`timemark`,`completed`,`is_ref`) VALUES (%s,0,%s,'%s',UNIX_TIMESTAMP(),'N','Y')",
                                                array(
-                                                       makeZeroToNull(determineReferralId()),
+                                                       convertZeroToNull(determineReferralId()),
                                                        (postRequestElement('points') * 2 * getConfig('doubler_ref') / 100),
                                                        detectRemoteAddr()
                                                ), __FILE__, __LINE__);