X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=inc%2Flibs%2Fdoubler_functions.php;h=2a2100f59272ed2a4613f8525377ed613aa071ff;hb=263a089d8a499e0e26d0af9e7aa7639f88b8ca60;hp=6d54679d7fb728dfc14bf38410d41dcdbbeeaf9c;hpb=c2e17d983fcbc0c3bd1dd37908d87c678f0367df;p=mailer.git diff --git a/inc/libs/doubler_functions.php b/inc/libs/doubler_functions.php index 6d54679d7f..2a2100f592 100644 --- a/inc/libs/doubler_functions.php +++ b/inc/libs/doubler_functions.php @@ -1,7 +1,7 @@ 0) { // Load entries only from a single user - $add = " AND `userid`='".bigintval($userid)."'"; + $add = sprintf(" AND `userid`=%s", bigintval($userid)); $mode = 'member'; $COLS = 4; $DT_MODE = 2; $message = getMessage('DOUBLER_MEMBER_NO_ENTRIES_FOUND'); } else { @@ -74,7 +74,7 @@ function generateDoublerTable ($userid = 0, $done = 'N', $ref = 'N', $sort = 'AS FROM `{?_MYSQL_PREFIX?}_doubler` WHERE - `completed`='".$done."' AND is_ref`='".$ref."'".$add." + `completed`='".$done."' AND `is_ref`='".$ref."'".$add." ORDER BY `timemark` ".$sort." LIMIT ".$limit, __FUNCTION__, __LINE__); @@ -92,11 +92,11 @@ LIMIT ".$limit, __FUNCTION__, __LINE__); // Prepare data for the row template $content = array( - 'userid' => $content['userid'], - 'rid' => $content['refid'], - 'points' => translateComma($content['points']), - 'stamp' => generateDateTime($content['timemark'], $DT_MODE), - 'sw' => $SW, + 'userid' => $content['userid'], + 'rid' => $content['refid'], + 'points' => translateComma($content['points']), + 'timemark' => generateDateTime($content['timemark'], $DT_MODE), + 'sw' => $SW, ); // Load template and switch color @@ -122,7 +122,7 @@ LIMIT ".$limit, __FUNCTION__, __LINE__); // function DOUBLER_GET_TOTAL_POINTS_LEFT() { // Initialize variables - $points = 0; + $points = '0'; if (getConfig('doubler_own') == 'Y') { // Take points from doubler's own account