X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-list_sponsor_pay.php;h=2e04f5f189e7609815d694a63c0a5096502919da;hb=0a69b4e17157eda9b6e1c70ff494292ccf8cbbd0;hp=149175e48d4429728c00e41e1617ecfbb3dfa453;hpb=9afd6ec5878544a7982c50ed9c0dd7de37606d5b;p=mailer.git diff --git a/inc/modules/admin/what-list_sponsor_pay.php b/inc/modules/admin/what-list_sponsor_pay.php index 149175e48d..2e04f5f189 100644 --- a/inc/modules/admin/what-list_sponsor_pay.php +++ b/inc/modules/admin/what-list_sponsor_pay.php @@ -1,7 +1,7 @@ $sel) { + foreach (postRequestParameter('id') as $id => $sel) { // Secure id $id = bigintval($id); @@ -82,19 +82,19 @@ WHERE `id`='%s' LIMIT 1", array( - postRequestElement('name', $id), - postRequestElement('rate', $id), - bigintval(postRequestElement('min', $id)), - postRequestElement('curr', $id), + postRequestParameter('name', $id), + postRequestParameter('rate', $id), + bigintval(postRequestParameter('min', $id)), + postRequestParameter('curr', $id), $id ), __FILE__, __LINE__); } // Generate message $message = getMessage('SPONSOR_PAY_ENTRIES_CHANGED'); - } elseif (isPostRequestElementSet('remove')) { + } elseif (isPostRequestParameterSet('remove')) { // Remove entries here... - foreach (postRequestElement('id') as $id => $sel) { + foreach (postRequestParameter('id') as $id => $sel) { // Remove entry SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_sponsor_paytypes` WHERE `id`='%s' LIMIT 1", array(bigintval($id)), __FILE__, __LINE__); @@ -110,36 +110,36 @@ LIMIT 1", } // END - if } -if (isPostRequestElementSet('add')) { +if (isPostRequestParameterSet('add')) { // Check if entry with same name does exists $result = SQL_QUERY_ESC("SELECT `id` FROM `{?_MYSQL_PREFIX?}_sponsor_paytypes` WHERE `pay_name`='%s' LIMIT 1", - array(postRequestElement('pay_name')), __FILE__, __LINE__); + array(postRequestParameter('pay_name')), __FILE__, __LINE__); if (SQL_NUMROWS($result) == '0') { // No entry found so add this line SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`, `pay_rate`, `pay_min_count`, `pay_currency`) VALUES ('%s','%s','%s','%s')", array( - postRequestElement('pay_name'), - convertCommaToDot(postRequestElement('pay_rate')), - bigintval(postRequestElement('pay_min_count')), - postRequestElement('pay_currency') + postRequestParameter('pay_name'), + convertCommaToDot(postRequestParameter('pay_rate')), + bigintval(postRequestParameter('pay_min_count')), + postRequestParameter('pay_currency') ), __FILE__, __LINE__); // Payment type added! - $message = sprintf(getMessage('ADMIN_SPONSOR_PAYTYPE_ADDED'), postRequestElement('pay_name')); + $message = getMaskedMessage('ADMIN_SPONSOR_PAYTYPE_ADDED', postRequestParameter('pay_name')); } else { // Free memory SQL_FREERESULT($result); // Entry does already exists - $message = sprintf(getMessage('ADMIN_SPONSOR_PAYTYPE_ALREADY'), postRequestElement('pay_name')); + $message = getMaskedMessage('ADMIN_SPONSOR_PAYTYPE_ALREADY', postRequestParameter('pay_name')); } // Output message loadTemplate('admin_settings_saved', false, $message); -} elseif ((isPostRequestElementSet('edit')) || (isPostRequestElementSet('del'))) { +} elseif ((isPostRequestParameterSet('edit')) || (isPostRequestParameterSet('del'))) { // Load all data $OUT = ''; $SW = 2; - foreach (postRequestElement('id') as $id => $sel) { + foreach (postRequestParameter('id') as $id => $sel) { // Load entry $result = SQL_QUERY_ESC("SELECT `pay_name`, `pay_rate`, `pay_min_count`, `pay_currency` FROM `{?_MYSQL_PREFIX?}_sponsor_paytypes` WHERE `id`='%s' LIMIT 1", array(bigintval($id)), __FILE__, __LINE__); @@ -158,7 +158,7 @@ if (isPostRequestElementSet('add')) { 'curr' => htmlspecialchars($curr) ); - if (isPostRequestElementSet('edit')) { + if (isPostRequestParameterSet('edit')) { // Edit entry $OUT .= loadTemplate('admin_list_sponsor_pay_edit_row', true, $content); } else { @@ -175,7 +175,7 @@ if (isPostRequestElementSet('add')) { } // END - foreach // Load main template depending on mode (edit/delete) - if (isPostRequestElementSet('edit')) { + if (isPostRequestParameterSet('edit')) { // Load main edit template loadTemplate('admin_list_sponsor_pay_edit', false, $OUT); } else {