public static function sendTestReminderEmails($to_email, $reminderId) { $isSent = false; $notify = new Cart66AdvancedNotifications(); $reminder = new Cart66MembershipReminders($reminderId); $from_email = $reminder->from_email; $from_name = $reminder->from_name; $head = $notify->buildEmailHeader($from_name, $from_email); $email_data = array('from_email' => $from_email, 'from_name' => $from_name, 'to_email' => $to_email, 'to_name' => '', 'copy_to' => '', 'head' => $head, 'subject' => $reminder->subject, 'msg' => $reminder->getReminderEmailMessage(null, $head['mime'], 'test'), 'attachments' => null, 'order_id' => '', 'email_type' => 'TEST', 'log' => 'test_emails', 'status' => 'test'); if ($reminder) { $isSent = $notify->sendEmail($email_data); } return $isSent; }
public static function sendTestEmail($sendTestTo, $status) { $isSent = false; $notify = new Cart66AdvancedNotifications(); $from_email = Cart66Setting::getValue($status . '_from_address'); $from_name = Cart66Setting::getValue($status . '_from_name'); $head = $notify->buildEmailHeader($from_name, $from_email); $email_data = array('from_email' => $from_email, 'from_name' => $from_name, 'to_email' => $sendTestTo, 'to_name' => '', 'copy_to' => '', 'head' => $head, 'subject' => __('TEST EMAIL', 'cart66') . ' --' . strtoupper($status) . '-- ' . Cart66Setting::getValue($status . '_subject'), 'msg' => $notify->getAdvancedEmailMessage(null, $head['mime'], 'test', Cart66Common::postVal('status')), 'msg_cc' => null, 'attachments' => null, 'order_id' => $notify->_order->id, 'email_type' => 'TEST', 'log' => 'test_emails', 'status' => 'test'); $isSent = $notify->sendEmail($email_data); return $isSent; }