Inconsistency between echo and print() fixed to OUTPUT_HTML() (not all)
[mailer.git] / inc / reset / reset_daily.php
index 87a9a10a63016917005d92ea1d0a65e8e9e59f2d..47ae3478de61dfb9194da322b639fe0603535c50 100644 (file)
@@ -46,7 +46,7 @@ if (!defined('__SECURITY')) {
 
 // Do not execute when script is in CSS mode or no daily reset
 if ((getOutputMode() == 1) || (!isResetModeEnabled())) return;
-//* DEBUG: */ echo basename(__FILE__)."<br />\n";
+//* DEBUG: */ OUTPUT_HTML(basename(__FILE__)."<br />");
 
 // Update user profiles
 if (GET_EXT_VERSION('order') >= '0.1.1') {
@@ -60,26 +60,26 @@ if (GET_EXT_VERSION('order') >= '0.1.1') {
 // Transfer points from locked_points to points
 $result_daily = SQL_QUERY("SELECT userid FROM `{!_MYSQL_PREFIX!}_user_data` WHERE ref_payout=0 AND `status`='CONFIRMED' ORDER BY `userid` ASC", __FILE__, __LINE__);
 
-//* DEBUG: */ echo basename(__FILE__).":payout=0;daily|numRows=".SQL_NUMROWS($result_daily)."<br />\n";
+//* DEBUG: */ OUTPUT_HTML(basename(__FILE__).":payout=0;daily|numRows=".SQL_NUMROWS($result_daily)."<br />");
 if (SQL_NUMROWS($result_daily) > 0) {
        // Init SQLs
        INIT_SQLS();
 
        // Start checking accounts which are on 0 confirmed-to-go mails
        while ($content = SQL_FETCHARRAY($result_daily)) {
-               //* DEBUG: */ echo basename(__FILE__).":uid={$content['userid']}<br />\n";
+               //* DEBUG: */ OUTPUT_HTML(basename(__FILE__).":uid={$content['userid']}<br />");
                $result_points = SQL_QUERY_ESC("SELECT ref_depth, locked_points FROM `{!_MYSQL_PREFIX!}_user_points`
 WHERE userid=%s AND locked_points != 0.00000 ORDER BY ref_depth",
                array(bigintval($content['userid'])), __FILE__, __LINE__);
 
-               //* DEBUG: */ echo basename(__FILE__).":payout=0;points|numRows=".SQL_NUMROWS($result_points)."<br />\n";
+               //* DEBUG: */ OUTPUT_HTML(basename(__FILE__).":payout=0;points|numRows=".SQL_NUMROWS($result_points)."<br />");
                if (SQL_NUMROWS($result_points) > 0) {
                        // Ok transfer points
                        while ($content2 = SQL_FETCHARRAY($result_points)) {
                                // Merge both arrays
                                $content = merge_array($content, $content2);
 
-                               //* DEBUG: */ echo basename(__FILE__).":uid={$content['userid']},depth={$content['ref_depth']},locked={$content['locked_points']}<br />\n";
+                               //* DEBUG: */ OUTPUT_HTML(basename(__FILE__).":uid={$content['userid']},depth={$content['ref_depth']},locked={$content['locked_points']}<br />");
                                ADD_SQL(SQL_QUERY_ESC("UPDATE `{!_MYSQL_PREFIX!}_user_points` SET points=points+%s, locked_points=0.00000
 WHERE userid=%s AND ref_depth=%d
 LIMIT 1",