X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=mailid_top.php;h=b88616de73d9260a7cfacbda1ad7d02c96937989;hp=c1d913a03b320d4de8926f570e906edae7a8649d;hb=ebcae81718f4fd253a51330a798a90eadbbe0ab5;hpb=c3b4eaf29946349ff058691db2dcb615a5379bb2 diff --git a/mailid_top.php b/mailid_top.php index c1d913a03b..b88616de73 100644 --- a/mailid_top.php +++ b/mailid_top.php @@ -15,6 +15,8 @@ * $Tag:: 0.2.1-FINAL $ * * $Author:: $ * * -------------------------------------------------------------------- * + * @TODO Merge this script with mailid.php * + * -------------------------------------------------------------------- * * Copyright (c) 2003 - 2009 by Roland Haeder * * Copyright (c) 2009 - 2011 by Mailer Developer Team * * For more information visit: http://www.mxchange.org * @@ -258,8 +260,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr array($userId), __FILE__, __LINE__); // Add points - // @TODO Try to rewrite the following unset() - unset($GLOBALS['ref_level']); + initReferalSystem(); addPointsThroughReferalSystem('mailid_okay', $userId, $payment); // Shall I add bonus points for "turbo clickers" ? @@ -267,7 +268,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr // Is an active-rallye running and this is not a notification mail? if ((isBonusRallyeActive()) && ($notify != 'Y')) { // Shall I exclude the webmaster's own userid from the active-rallye? - if ((((getBonusUserId() == $userId) && (getConfig('bonus_include_own') == 'Y')) || (getBonusUserId() != $userId)) && (getDefRefid() != $userId)) { + if ((((getBonusUserid() == $userId) && (getConfig('bonus_include_own') == 'Y')) || (getBonusUserid() != $userId)) && (getDefRefid() != $userId)) { // Add points and remember ranking are done in this function.... addTurboBonus($urlId, $userId, $type); @@ -288,7 +289,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr } // END - if // Load total points - $content['total'] = getTotalPoints($userId); + $content['total_points'] = getTotalPoints($userId); // Add payment points $content['points'] = $payment; @@ -297,7 +298,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr loadTemplate($template, false, $content); } elseif (isValidUserId($sender)) { // Wrong image code! So add points to sender's account - addPointsDirectly('mailid_payback', $sender, $payment); + addPointsThroughReferalSystem('mailid_payback', $sender, $payment); // Load template loadTemplate('mailid_points_failed', false, $content);