loadTemplate('admin_edit_email', FALSE, $content);
} elseif ((isPostRequestElementSet('id')) && (isGetRequestElementSet('type')) && (postRequestElement('type') == 'bonus')) {
// Make also this email editable
- $result = SQL_QUERY_ESC('SELECT
+ $result = sqlQueryEscaped('SELECT
`id`,
`subject`,
`text`,
array(bigintval(getRequestElement('id'))), __FILE__, __LINE__);
// Fetch row
- $content = SQL_FETCHARRAY($result);
+ $content = sqlFetchArray($result);
// Free result
- SQL_FREERESULT($result);
+ sqlFreeResult($result);
// Load template
loadTemplate('admin_edit_bonus_email', FALSE, $content);
}
} elseif ((isPostRequestElementSet('id')) && (isGetRequestElementSet('type')) && (postRequestElement('type') == 'bonus')) {
// Update pool
- SQL_QUERY_ESC("UPDATE
+ sqlQueryEscaped("UPDATE
`{?_MYSQL_PREFIX?}_bonus`
SET
`subject`='%s',
bigintval(postRequestElement('id')),
), __FILE__, __LINE__);
- if (!SQL_HASZEROAFFECTED()) {
+ if (!ifSqlHasZeroAffectedRows()) {
$content = '{--ADMIN_EMAIL_CHANGES_SAVED--}';
} else {
$content = '<span class="bad">{--ADMIN_EMAIL_CHANGES_NOT_SAVED--}</span>';
displayMessage($content);
} else {
// Query the pool
- $result = SQL_QUERY('SELECT
+ $result = sqlQuery('SELECT
`id`,
`sender`,
`subject`,
`timestamp` ASC', __FILE__, __LINE__);
// Entries found?
- if (!SQL_HASZERONUMS($result)) {
+ if (!ifSqlHasZeroNums($result)) {
// There are mail orders available
$OUT = '';
- while ($content = SQL_FETCHARRAY($result)) {
+ while ($content = sqlFetchArray($result)) {
// Load row template and switch colors
$OUT .= loadTemplate('admin_edit_email_row', TRUE, $content);
} // END - while
// Free memory
- SQL_FREERESULT($result);
+ sqlFreeResult($result);
// Load email template
loadTemplate('admin_edit_email_select', FALSE, $OUT);