本文整理汇总了PHP中AWS_APP::mail方法的典型用法代码示例。如果您正苦于以下问题:PHP AWS_APP::mail方法的具体用法?PHP AWS_APP::mail怎么用?PHP AWS_APP::mail使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AWS_APP
的用法示例。
在下文中一共展示了AWS_APP::mail方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: send_mail_queue
public function send_mail_queue($limit = 10)
{
if ($mail_queue = $this->fetch_all('mail_queue', 'is_error = 0', 'id ASC', $limit)) {
foreach ($mail_queue as $key => $val) {
if ($error_message = AWS_APP::mail()->send($val['send_to'], $val['subject'], $val['message'], get_setting('site_name'), null, 'master')) {
$this->shutdown_update('mail_queue', array('is_error' => 1, 'error_message' => $error_message), 'id = ' . $val['id']);
} else {
$this->delete('mail_queue', 'id = ' . intval($val['id']));
}
}
}
}
示例2: show_error
function show_error($exception_message, $error_message = '')
{
@ob_end_clean();
if (get_setting('report_diagnostics') == 'Y' and class_exists('AWS_APP', false)) {
AWS_APP::mail()->send('wecenter_report@outlook.com', '[' . G_VERSION . '][' . G_VERSION_BUILD . '][' . base_url() . ']' . $error_message, nl2br($exception_message), get_setting('site_name'), 'WeCenter');
}
echo _show_error($exception_message);
exit;
}
示例3: mail
/**
* 获取系统邮件处理类
*
* 调用 core/mail.php
*
* @access public
* @return object
*/
public static function mail()
{
if (!self::$mail) {
self::$mail = load_class('core_mail');
}
return self::$mail;
}
示例4: reply_answer_by_email
public function reply_answer_by_email($question_id, $comment)
{
$received_email = $this->fetch_row('received_email', 'question_id = ' . intval($question_id));
if (!$received_email or !$received_email['from']) {
return false;
}
$comment .= ' <br /> <a href="' . get_js_url('/question/' . $question_id) . ' target="_blank">' . AWS_APP::lang()->_t('查看问题详情') . '</a>';
return AWS_APP::mail()->send($received_email['from'], 'RE: ' . $received_email['subject'], $comment, get_setting('site_name'));
}
示例5: email_setting_test_action
public function email_setting_test_action()
{
if ($error_message = AWS_APP::mail()->send($_POST['test_email'], get_setting('site_name') . ' - ' . AWS_APP::lang()->_t('邮件服务器配置测试'), AWS_APP::lang()->_t('这是一封测试邮件,收到邮件表示邮件服务器配置成功'), get_setting('site_name'))) {
H::ajax_json_output(AWS_APP::RSM(null, -1, AWS_APP::lang()->_t('测试邮件发送失败, 返回的信息: %s', strip_tags($error_message))));
} else {
H::ajax_json_output(AWS_APP::RSM(null, -1, AWS_APP::lang()->_t('测试邮件已发送, 请查收邮件测试配置是否正确')));
}
}
示例6: reply_answer_by_email
public function reply_answer_by_email($question_id, $comment)
{
$received_email = $this->fetch_row('received_email', 'question_id = ' . intval($question_id));
if (!$received_email or !$received_email['from']) {
return false;
}
return AWS_APP::mail()->send($received_email['from'], 'RE: ' . $received_email['subject'], $comment, get_setting('site_name'));
}