From 6f08113c0bd6d49d8417e214031c839aedfc2ca0 Mon Sep 17 00:00:00 2001 From: Christian Fowler Date: Fri, 4 May 2007 16:40:20 +0000 Subject: add test_mode to enable resending message, hide validated only option for now --- admin/send.php | 10 +++++----- admin/tend_mail_queue.php | 12 ++---------- 2 files changed, 7 insertions(+), 15 deletions(-) (limited to 'admin') diff --git a/admin/send.php b/admin/send.php index f1a1232..8156b0f 100644 --- a/admin/send.php +++ b/admin/send.php @@ -1,6 +1,6 @@ assign('preview', 'n'); $gBitSmarty->assign('presend', 'n'); $gBitSmarty->assign('emited', 'n'); -$validated = (isset($_REQUEST["validated"]) && !empty($_REQUEST["validated"])) ? TRUE : FALSE; +$validated = !empty( $_REQUEST["validated"] ) ? TRUE : FALSE; if( $gContent->isValid() && isset( $_REQUEST['preview'] ) && isset( $_REQUEST['send_group'] ) ) { - $recipients = $gContent->getRecipients( $_REQUEST['send_group'], $validated ); + $recipients = $gContent->getRecipients( $_REQUEST['send_group'], $validated, !empty( $_REQUEST['test_mode'] ) ); $gBitSmarty->assign_by_ref( 'recipientList', $recipients ); $gBitSmarty->assign( 'validated', $validated ); $gBitSmarty->assign( 'sending', TRUE ); } elseif( $gContent->isValid() && isset( $_REQUEST["send"] ) ) { - if( $emails = $gContent->getRecipients( $_REQUEST['send_group'], $validated ) ) { + if( $emails = $gContent->getRecipients( $_REQUEST['send_group'], $validated, !empty( $_REQUEST['test_mode'] ) ) ) { global $gBitMailer; $gBitMailer = new BitMailer(); - $gBitMailer->queueRecipients( $gContent->mContentId, $gContent->mNewsletter->mContentId, $emails ); + $gBitMailer->queueRecipients( $gContent->mContentId, $gContent->mNewsletter->mContentId, $emails, !empty( $_REQUEST['test_mode'] ) ); $feedback['success'] = count( $emails ).' '.tra( 'emails were queued to be sent:' ).' '.$gContent->getTitle(); $gContent->mEditionId = NULL; } else { diff --git a/admin/tend_mail_queue.php b/admin/tend_mail_queue.php index 14f815b..61c7a0a 100644 --- a/admin/tend_mail_queue.php +++ b/admin/tend_mail_queue.php @@ -1,13 +1,6 @@ tendQueue(); } -- cgit v1.3