X-Git-Url: https://git.mxchange.org/?p=mailer.git;a=blobdiff_plain;f=inc%2Fmodules%2Fmember%2Fwhat-order.php;h=f7f6049d476c639335c05301b4b41911a7b90475;hp=b214a719c614beb8a81c0a429909c4784ef17b04;hb=c2e17d983fcbc0c3bd1dd37908d87c678f0367df;hpb=d49fe31440f5946f23cd2b4044c6e0256640dde4 diff --git a/inc/modules/member/what-order.php b/inc/modules/member/what-order.php index b214a719c6..f7f6049d47 100644 --- a/inc/modules/member/what-order.php +++ b/inc/modules/member/what-order.php @@ -275,7 +275,7 @@ LIMIT 1", // Update receiver list SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_user_data` SET `receive_mails`=`receive_mails`-1 WHERE `userid` IN (%s) LIMIT %s", - array(str_replace(';', ", ", $RECEIVER), $content['target_send']), __FILE__, __LINE__); + array(convertReceivers($RECEIVER), $content['target_send']), __FILE__, __LINE__); // Is calculated max receivers larger than wanted receivers then reset it if ($content['target_send'] > postRequestElement('receiver')) $content['target_send'] = bigintval(postRequestElement('receiver')); @@ -284,12 +284,12 @@ LIMIT 1", $USED = $content['target_send'] * getPaymentPoints(bigintval(postRequestElement('type'))); // Fix empty zip code - if (!isPostRequestElementSet('zip')) setRequestPostElement('zip', '0'); + if (!isPostRequestElementSet('zip')) setRequestPostElement('zip', 0); // Check if he has enougth points for this order and selected more than 0 receivers if (($USED > 0) && ($USED <= $total) && ($content['target_send'] > 0)) { // Gettings points is okay, so we can add $USED later from - if (($id == '0') || ($type != 'TEMP')) { + if (($id == 0) || ($type != 'TEMP')) { // New order $id = 0; if (isExtensionActive('html_mail')) { @@ -418,13 +418,13 @@ LIMIT 1", $URL = 'modules.php?module=login&what=order&code=' . getCode('NO_RECS_LEFT'); } } -} elseif (postRequestElement('receiver') == '0') { +} elseif (postRequestElement('receiver') == 0) { // Not enougth receivers selected $URL = 'modules.php?module=login&what=order&code=' . getCode('MORE_RECEIVERS1'); } elseif (($ALLOWED == 0) && (getConfig('order_max_full') == 'ORDER')) { // No more mail orders allowed loadTemplate('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` @@ -684,7 +684,7 @@ LIMIT 1", // No cateogries are defined yet loadTemplate('admin_settings_saved', false, "{--MEMBER_NO_CATS--}"); } -} elseif ($mmails == '0') { +} elseif ($mmails == 0) { // Please set more than 0 mails per day loadTemplate('admin_settings_saved', false, getMessage('MEMBER_HAS_ZERO_MMAILS')); } else {