ADD_DESCR("guest", basename(__FILE__));
$MODE = "";
-if (!empty($HTTP_GET_VARS['mode']))
+if (!empty($_GET['mode']))
{
// A "special" mode of the login system was requested
- switch ($HTTP_GET_VARS['mode'])
+ switch ($_GET['mode'])
{
case "activate" : $MODE = "activate"; break; // Activation link requested
case "lost_pass": $MODE = "lost_pass"; break; // Request new password
}
// Check if hash for confirmation of email address is given...
-if (!empty($HTTP_GET_VARS['hash']))
+if (!empty($_GET['hash']))
{
// Lookup sponsor
$result = SQL_QUERY_ESC("SELECT id, status, salut, surname, family,
points_amount AS points, last_pay AS pay, last_curr AS curr
FROM "._MYSQL_PREFIX."_sponsor_data
WHERE hash='%s' AND (status='UNCONFIRMED' OR status='EMAIL')
-LIMIT 1", array($HTTP_GET_VARS['hash']), __FILE__, __LINE__);
+LIMIT 1", array($_GET['hash']), __FILE__, __LINE__);
if (SQL_NUMROWS($result) == 1)
{
// Sponsor found, load his data...
// Set account to pending
$result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_sponsor_data SET status='PENDING'
WHERE id='%s' AND hash='%s' AND status='UNCONFIRMED' LIMIT 1",
- array(bigintval($SPONSOR['id']), $HTTP_GET_VARS['hash']), __FILE__, __LINE__);
+ array(bigintval($SPONSOR['id']), $_GET['hash']), __FILE__, __LINE__);
// Check on success
if (SQL_AFFECTEDROWS($link) == 1)
SEND_EMAIL($SPONSOR['email'], SPONSOR_ACCOUNT_PENDING_SUBJ, $MSG);
// Send email to admin
- if (GET_EXT_VERSION("admins") >= "0.4.1")
- {
- // Use new system
- SEND_ADMIN_EMAILS_PRO (ADMIN_NEW_SPONSOR, "admin_sponsor_pending", $SPONSOR);
- }
- else
- {
- // Send over old system
- $msg_admin = LOAD_EMAIL_TEMPLATE("admin_sponsor_pending", $SPONSOR);
- SEND_ADMIN_EMAILS (ADMIN_NEW_SPONSOR, $msg_admin);
- }
+ SEND_ADMIN_NOTIFICATION(ADMIN_NEW_SPONSOR, "admin_sponsor_pending", $SPONSOR);
// Sponsor account set to pending
LOAD_TEMPLATE("admin_settings_saved", false, SPONSOR_ACCOUNT_IS_PENDING);
// Changed email adress need to be confirmed
$result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_sponsor_data SET status='CONFIRMED'
WHERE id='%s' AND hash='%s' AND status='EMAIL' LIMIT 1",
- array(bigintval($SPONSOR['id']), $HTTP_GET_VARS['hash']), __FILE__, __LINE__);
+ array(bigintval($SPONSOR['id']), $_GET['hash']), __FILE__, __LINE__);
// Check on success
if (SQL_AFFECTEDROWS($link) == 1)