X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Flibs%2Frefback_functions.php;h=5d04dde4814bacde57e6cc1a47350eb9f6e3d136;hb=076e28c32b079b93b73a67b0c8710d65596b76a9;hp=6e5c9112ba2130e48541d207817a57214236657a;hpb=7f104f6fe558bb56b4205241435a2357c2feece1;p=mailer.git diff --git a/inc/libs/refback_functions.php b/inc/libs/refback_functions.php index 6e5c9112ba..5d04dde481 100644 --- a/inc/libs/refback_functions.php +++ b/inc/libs/refback_functions.php @@ -54,9 +54,9 @@ function ADD_REFBACK_POINTS ($uid, $ref, $points, $ref_points) { // "Walk" through all level while (list($level, $perc) = SQL_FETCHROW($result_refs)) { // Reset ref depths - $DEPTH = -1; + unset($DEPTH); - // "Walk through all refids + // "Walk" through all refids //* DEBUG: */ print __FUNCTION__."(".__LINE__."):uid={$uid},ref={$ref},level={$level},points={$points}
\n"; foreach (GET_REFBACK_USERID_ARRAY($uid, $level) as $refid) { // Skip level zero or if both are the same @@ -69,7 +69,7 @@ function ADD_REFBACK_POINTS ($uid, $ref, $points, $ref_points) { // Some percents given? if ($percents > 0) { //* DEBUG: */ print __FUNCTION__."(".__LINE__."):points={$points},perc={$perc},percents={$percents},level={$level}
\n"; - // Get points for refback + // Calculate points for refback $refback = $points * ($perc / 100) * ($percents / 100); // Update refback table ("refid" and "uid" must be exchanged!) @@ -123,7 +123,7 @@ function GET_REFBACK_PERCENTS ($uid, $ref) { } else { // Debug log //* DEBUG: */ print __FUNCTION__."(".__LINE__."): NO ENTRY FOUND! :-(
\n"; - DEBUG_LOG(__FUNCTION__.": uid={$uid},ref={$ref} - No entry found! :-("); + DEBUG_LOG(__FUNCTION__, __LINE__, " uid={$uid},ref={$ref} - No entry found! :-("); } // Free result @@ -170,7 +170,7 @@ function UPDATE_REFBACK_TABLE($uid) { //* DEBUG: */ print "----------------------- ".__FUNCTION__." - ENTRY ------------------------