X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=birthday_confirm.php;h=70332e33f76b089126513652de93ad298407de55;hp=003c93fbd186e359dbf95f9e477f5d7720b250ff;hb=509ae618cc32ba2b811cf66567d62abc597dc405;hpb=0fd6858b423d41e7eee9ffa3d5138d318e08cc1c diff --git a/birthday_confirm.php b/birthday_confirm.php index 003c93fbd1..70332e33f7 100644 --- a/birthday_confirm.php +++ b/birthday_confirm.php @@ -39,9 +39,8 @@ // Load security stuff here require('inc/libs/security_functions.php'); -// Init "action" and "what" -$GLOBALS['what'] = ''; -$GLOBALS['action'] = ''; +// Init start time +$GLOBALS['startTime'] = microtime(true); // Set module $GLOBALS['module'] = 'birthday_confirm'; @@ -67,11 +66,16 @@ $chk = bigintval(REQUEST_GET('check'), false); // Check if link is not clicked so far $result = SQL_QUERY_ESC("SELECT b.points, d.gender, d.surname, d.family, d.status, d.ref_payout -FROM `{!_MYSQL_PREFIX!}_user_birthday` AS b -INNER JOIN `{!_MYSQL_PREFIX!}_user_data` AS d -ON b.userid=d.userid -WHERE b.userid=%s AND b.chk_value='%s' LIMIT 1", -array($uid, $chk), __FILE__, __LINE__); +FROM + `{!_MYSQL_PREFIX!}_user_birthday` AS b +INNER JOIN + `{!_MYSQL_PREFIX!}_user_data` AS d +ON + b.userid=d.userid +WHERE + b.userid=%s AND b.chk_value='%s' +LIMIT 1", + array($uid, $chk), __FILE__, __LINE__); //* DEBUG: */ echo "uid=".$uid.",chk=".$chk." (".strlen($chk).'/'.strlen(REQUEST_GET('check')).'/'.SQL_NUMROWS($result).")
\n"; // Prepare content @@ -99,7 +103,7 @@ if (SQL_NUMROWS($result) == 1) { } // END - if // Remove entry from table - SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_user_birthday` WHERE userid=%s AND chk_value='%s' LIMIT 1", + SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{!_MYSQL_PREFIX!}_user_birthday` WHERE `userid`=%s AND `chk_value`='%s' LIMIT 1", array($uid, $chk), __FILE__, __LINE__); // "Translate" some data