}
$mode = '';
-if (isGetRequestParameterSet('mode')) {
+if (isGetRequestElementSet('mode')) {
// A "special" mode of the login system was requested
- switch (getRequestParameter('mode')) {
+ switch (getRequestElement('mode')) {
case 'activate' : $mode = 'activate'; break; // Activation link requested
case 'lost_pass': $mode = 'lost_pass'; break; // Request new password
} // END - switch
} // END - if
// Check if hash for confirmation of email address is given...
-if (isGetRequestParameterSet('hash')) {
+if (isGetRequestElementSet('hash')) {
// Lookup sponsor
$result = SQL_QUERY_ESC("SELECT
`id`,`status`,`gender`,`surname`,`family`,
`status`='UNCONFIRMED' OR
`status`='EMAIL'
)
-LIMIT 1", array(getRequestParameter('hash')), __FILE__, __LINE__);
+LIMIT 1", array(getRequestElement('hash')), __FILE__, __LINE__);
if (SQL_NUMROWS($result) == 1) {
// Sponsor found, load his data...
$data = SQL_FETCHARRAY($result);
LIMIT 1",
array(
bigintval($data['id']),
- getRequestParameter('hash')
+ getRequestElement('hash')
), __FILE__, __LINE__);
// Check on success
`hash`='%s' AND
`status`='EMAIL'
LIMIT 1",
- array(bigintval($data['id']), getRequestParameter('hash')), __FILE__, __LINE__);
+ array(bigintval($data['id']), getRequestElement('hash')), __FILE__, __LINE__);
// Check on success
if (!SQL_HASZEROAFFECTED()) {
}
} else {
// No sponsor found
- displayMessage('{%message,SPONSOR_ACCOUNT_404=' . getRequestParameter('hash') . '%}');
+ displayMessage('{%message,SPONSOR_ACCOUNT_404=' . getRequestElement('hash') . '%}');
}
// Free memory
// Send activation link again
if (isFormSent()) {
// Check submitted data
- if (!isPostRequestParameterSet('email')) unsetPostRequestParameter('ok');
+ if (!isPostRequestElementSet('email')) unsetPostRequestElement('ok');
}
if (isFormSent()) {
'%s' REGEXP `email` AND
(`status`='UNCONFIRMED' OR `status`='EMAIL')
LIMIT 1",
- array(postRequestParameter('email')), __FILE__, __LINE__);
+ array(postRequestElement('email')), __FILE__, __LINE__);
// Entry found?
if (SQL_NUMROWS($result) == 1) {
// Confirmed email address
$message_sponsor = loadEmailTemplate('sponsor_email', $data);
}
- sendEmail(postRequestParameter('email'), '{--SPONSOR_ACTIVATION_LINK_SUBJECT--}', $message_sponsor);
+ sendEmail(postRequestElement('email'), '{--SPONSOR_ACTIVATION_LINK_SUBJECT--}', $message_sponsor);
// Output message
displayMessage('{--SPONSOR_ACTIVATION_LINK_SENT--}');
// Send new password
if (isFormSent()) {
// Check submitted data
- if (!isPostRequestParameterSet('email')) unsetPostRequestParameter('ok');
+ if (!isPostRequestElementSet('email')) unsetPostRequestElement('ok');
} // END - if
if (isFormSent()) {
`id`=%s AND
`status`='CONFIRMED'
LIMIT 1",
- array(postRequestParameter('email'), bigintval(postRequestParameter('id'))), __FILE__, __LINE__);
+ array(postRequestElement('email'), bigintval(postRequestElement('id'))), __FILE__, __LINE__);
// Entry found?
if (SQL_NUMROWS($result) == 1) {
// Prepare email and send it to the sponsor
$message_sponsor = loadEmailTemplate('sponsor_lost', $content);
- sendEmail(postRequestParameter('email'), '{--SPONSOR_LOST_PASSWORD_SUBJECT--}', $message_sponsor);
+ sendEmail(postRequestElement('email'), '{--SPONSOR_LOST_PASSWORD_SUBJECT--}', $message_sponsor);
// Update password
SQL_QUERY_ESC("UPDATE
`password`='%s'
LIMIT 1",
array(
- bigintval(postRequestParameter('sponsor_id')),
- md5(postRequestParameter('password'))
+ bigintval(postRequestElement('sponsor_id')),
+ md5(postRequestElement('password'))
), __FILE__, __LINE__);
if (SQL_NUMROWS($result) == 1) {
list($status) = SQL_FETCHROW($result);
if ($status == 'CONFIRMED') {
// Is confirmed so both is fine and we can continue with login procedure
- $login = ((setSession('sponsor_id' , bigintval(postRequestParameter('sponsor_id')))) &&
- (setSession('sponsor_pass', md5(postRequestParameter('password')) ))
+ $login = ((setSession('sponsor_id' , bigintval(postRequestElement('sponsor_id')))) &&
+ (setSession('sponsor_pass', md5(postRequestElement('password')) ))
);
if ($login === true) {