X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=mailid_top.php;h=36a5c007856fbe55ff9fffaa52399a9f51bd51f9;hp=e9afe997ddc1b326fb1f7472949e5d798a2af586;hb=1fd39b2564946ce7f19776abab8d65a31928fba1;hpb=04b69ac9f33369cbf654396c4a42cb1fff710ff4 diff --git a/mailid_top.php b/mailid_top.php index e9afe997dd..36a5c00785 100644 --- a/mailid_top.php +++ b/mailid_top.php @@ -74,7 +74,7 @@ if (isGetRequestParameterSet('code')) $code = bigintval(getRequestParam if (isGetRequestParameterSet('mode')) $mode = getRequestParameter('mode'); // 01 1 12 2 2 21 1 22 10 -if (($url_userid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (!ifFatalErrorsDetected())) { +if ((isValidUserId($url_userid)) && (($url_mid > 0) || ($url_bid > 0)) && (!ifFatalErrorsDetected())) { // No image? Then output header if ($mode != 'img') loadIncludeOnce('inc/header.php'); @@ -215,7 +215,6 @@ if (($url_userid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (!ifFatalErrorsDe } // END - switch // Export data into constants for the template - $content['points'] = translateComma($payment); $content['banner'] = loadTemplate('mailid_banner', true); // Only when user extension = v0.1.2: Update mails-confirmed counter @@ -261,9 +260,9 @@ if (($url_userid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (!ifFatalErrorsDe // Shall I add bonus points for "turbo clickers" ? if (isExtensionInstalledAndNewer('bonus', '0.2.2')) { // Is an active-rallye running and this is not a notification mail? - if ((getConfig('bonus_active') == 'Y') && ($notify != 'Y')) { + if ((isBonusRallyeActive()) && ($notify != 'Y')) { // Shall I exclude the webmaster's own userid from the active-rallye? - if ((((getConfig('bonus_userid') == $url_userid) && (getConfig('bonus_include_own') == 'Y')) || (getConfig('bonus_userid') != $url_userid)) && (getConfig('def_refid') != $url_userid)) { + if ((((getBonusUserId() == $url_userid) && (getConfig('bonus_include_own') == 'Y')) || (getBonusUserId() != $url_userid)) && (getConfig('def_refid') != $url_userid)) { // Add points and remember ranking are done in this function.... addTurboBonus($urlId, $url_userid, $type); @@ -278,14 +277,11 @@ if (($url_userid) > 0 && (($url_mid > 0) || ($url_bid > 0)) && (!ifFatalErrorsDe } // END - if // Load total points - $content['total'] = translateComma( - countSumTotalData($url_userid, 'user_points', 'points') - - countSumTotalData($url_userid, 'user_data', 'used_points') - ); + $content['total'] = getTotalPoints($url_userid); // Load template loadTemplate($template, false, $content); - } elseif ($sender > 0) { + } elseif (isValidUserId($sender)) { // Wrong image code! So add points to sender's account addPointsDirectly('mailid_payback', $sender, $payment);