}
// ID is received so we can redirect the user, used points will be added when he send's out the mail
- $URL = "modules.php?module=frametester&order=".$id."";
+ $URL = 'modules.php?module=frametester&order=' . $id;
} elseif ($MAX_SEND == 0) {
// Not enougth receivers found which can receive mails
$URL = 'modules.php?module=login&what=order&msg=' . getCode('MORE_RECEIVERS2');
$URL = 'modules.php?module=login&what=order&msg=' . getCode('NO_RECS_LEFT');
}
}
-} elseif (REQUEST_POST('receiver') == "0") {
+} elseif (REQUEST_POST('receiver') == '0') {
// Not enougth receivers selected
$URL = 'modules.php?module=login&what=order&msg=' . getCode('MORE_RECEIVERS1');
} elseif (($ALLOWED == 0) && (getConfig('order_max_full') == 'ORDER')) {
// No more mail orders allowed
LOAD_TEMPLATE('admin_settings_saved', false, getMessage('MEMBER_ORDER_ALLOWED_EXHAUSTED'));
-} elseif (($links < getConfig('unconfirmed')) && ($mmails == "1")) {
+} elseif (($links < getConfig('unconfirmed')) && ($mmails == '1')) {
// Display order form
$result_cats = SQL_QUERY("SELECT id, cat FROM `{!_MYSQL_PREFIX!}_cats`".$whereStatement." ORDER BY `sort`", __FILE__, __LINE__);
if (SQL_NUMROWS($result_cats) > 0) {
);
// Enable HTML checking
+ // @TODO Rewrite this to a filter
$HTML = ''; $HOLIDAY = false; $HOL_STRING = '';
- if ((EXT_IS_ACTIVE('html_mail')) && (REQUEST_POST('html') == 'Y')) $HTML = " AND html='Y'";
+ if ((EXT_IS_ACTIVE('html_mail')) && (REQUEST_POST('html') == 'Y')) $HTML = " AND `html`='Y'";
if (GET_EXT_VERSION('holiday') >= '0.1.3') {
// Extension's version is fine
- $HOLIDAY = true; $HOL_STRING = " AND holiday_active='N'";
+ $HOLIDAY = true; $HOL_STRING = " AND `holiday_active`='N'";
} // END - if
// ... and begin loading stuff
$result_holiday = SQL_QUERY_ESC("SELECT DISTINCT d.userid FROM `{!_MYSQL_PREFIX!}_user_data` AS d
LEFT JOIN `{!_MYSQL_PREFIX!}_user_holidays` AS h
ON d.userid=h.userid
-WHERE d.userid=%s AND d.receive_mails > 0 AND d.`status`='CONFIRMED' AND d.holiday_active='Y'
+WHERE d.userid=%s AND d.receive_mails > 0 AND d.`status`='CONFIRMED' AND d.`holiday_active`='Y'
AND h.holiday_start < UNIX_TIMESTAMP() AND h.holiday_end > UNIX_TIMESTAMP()
LIMIT 1", array(bigintval($ucat)), __FILE__, __LINE__);
if (SQL_NUMROWS($result_holiday) == 1) {
switch (getConfig('order_max_full'))
{
case 'MAX': // He is allowed to send as much as possible
- define('ORDER_MAX_VALUE', getMessage('ORDER_ALLOWED_MAX'));
+ define('ORDER_MAX_VALUE', getMessage('MEMBER_ORDER_ALLOWED_MAX'));
break;
case 'ORDER': // He is allowed to send as much as he setup the receiving value
- define('ORDER_MAX_VALUE', sprintf(getMessage('ORDER_ALLOWED_RECEIVE'), $ALLOWED, $MAXI));
+ define('ORDER_MAX_VALUE', sprintf(getMessage('MEMBER_ORDER_ALLOWED_RECEIVE'), $ALLOWED, $MAXI));
break;
default: // Unknown/invalid
DEBUG_LOG(__FILE__, __LINE__, sprintf("Unknown order_mas_full config detected.", getConfig('order_max_full')));
- define('ORDER_MAX_VALUE', getMessage('ORDER_ALLOWED_UNKNOWN'));
+ define('ORDER_MAX_VALUE', getMessage('MEMBER_ORDER_ALLOWED_UNKNOWN'));
break;
}