本文整理汇总了PHP中es_cls_common::es_sent_report_html方法的典型用法代码示例。如果您正苦于以下问题:PHP es_cls_common::es_sent_report_html方法的具体用法?PHP es_cls_common::es_sent_report_html怎么用?PHP es_cls_common::es_sent_report_html使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类es_cls_common
的用法示例。
在下文中一共展示了es_cls_common::es_sent_report_html方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: es_sendmail
//.........这里部分代码省略.........
if ($settings['es_c_mailtype'] == "WP HTML MAIL" || $settings['es_c_mailtype'] == "PHP HTML MAIL") {
$content_send = nl2br($content_send);
$content_send = str_replace($replacefrom, $replaceto, $content_send);
} else {
$content_send = str_replace("<br />", "\r\n", $content_send);
$content_send = str_replace("<br>", "\r\n", $content_send);
}
break;
case 'notification':
// notification mail to subscribers
$unsublink = $settings['es_c_unsublink'];
$unsublink = str_replace("###DBID###", $subscriber["es_email_id"], $unsublink);
$unsublink = str_replace("###EMAIL###", $subscriber["es_email_mail"], $unsublink);
$unsublink = str_replace("###GUID###", $subscriber["es_email_guid"], $unsublink);
$unsublink = $unsublink . "&cache=" . $cacheid;
$unsubtext = stripslashes($settings['es_c_unsubtext']);
$unsubtext = str_replace("###LINK###", $unsublink, $unsubtext);
if ($settings['es_c_mailtype'] == "WP HTML MAIL" || $settings['es_c_mailtype'] == "PHP HTML MAIL") {
$unsubtext = '<br><br>' . $unsubtext;
} else {
$unsubtext = '\\n\\n' . $unsubtext;
}
$returnid = es_cls_delivery::es_delivery_ins($sendguid, $subscriber["es_email_id"], $subscriber["es_email_mail"]);
$viewstslink = str_replace("###DELVIID###", $returnid, $viewstatus);
$content_send = str_replace("###EMAIL###", $subscriber["es_email_mail"], $content);
$content_send = str_replace("###NAME###", $subscriber["es_email_name"], $content_send);
if ($settings['es_c_mailtype'] == "WP HTML MAIL" || $settings['es_c_mailtype'] == "PHP HTML MAIL") {
$content_send = nl2br($content_send);
$content_send = str_replace($replacefrom, $replaceto, $content_send);
} else {
$content_send = str_replace("<br />", "\r\n", $content_send);
$content_send = str_replace("<br>", "\r\n", $content_send);
}
break;
}
if ($wpmail) {
// Users mails
if ($type == "welcome") {
if ($es_c_usermailoption == "YES") {
wp_mail($to, $subject, $content_send . $unsubtext . $viewstslink, $headers);
}
} else {
wp_mail($to, $subject, $content_send . $unsubtext . $viewstslink, $headers);
}
// Admin mails
if ($type == "welcome" && $adminmail != "" && $es_c_adminmailoption == "YES") {
wp_mail($adminmail, $adminmailsubject, $adminmailcontant, $headers);
}
} else {
// Users mails
if ($type == "welcome") {
if ($es_c_usermailoption == "YES") {
mail($to, $subject, $content_send . $unsubtext . $viewstslink, $headers);
}
} else {
mail($to, $subject, $content_send . $unsubtext . $viewstslink, $headers);
}
// Admin mails
if ($type == "welcome" && $adminmail != "" && $es_c_adminmailoption == "YES") {
mail($adminmail, $adminmailsubject, $adminmailcontant, $headers);
}
}
$count = $count + 1;
}
}
if ($type == "newsletter" || $type == "notification") {
$count = $count - 1;
es_cls_sentmail::es_sentmail_ups($sendguid);
if ($adminmail != "") {
$subject = get_option('es_c_sentreport_subject', 'nosubjectexists');
if ($subject == "" || $subject == "nosubjectexists") {
$subject = es_cls_common::es_sent_report_subject();
}
if ($htmlmail) {
$reportmail = get_option('es_c_sentreport', 'nooptionexists');
if ($reportmail == "" || $reportmail == "nooptionexists") {
$reportmail = es_cls_common::es_sent_report_html();
}
$reportmail = nl2br($reportmail);
} else {
$reportmail = get_option('es_c_sentreport', 'nooptionexists');
if ($reportmail == "" || $reportmail == "nooptionexists") {
$reportmail = es_cls_common::es_sent_report_plain();
}
$reportmail = str_replace("<br />", "\r\n", $reportmail);
$reportmail = str_replace("<br>", "\r\n", $reportmail);
}
$enddate = date('Y-m-d G:i:s');
$reportmail = str_replace("###COUNT###", $count, $reportmail);
$reportmail = str_replace("###UNIQUE###", $sendguid, $reportmail);
$reportmail = str_replace("###STARTTIME###", $currentdate, $reportmail);
$reportmail = str_replace("###ENDTIME###", $enddate, $reportmail);
if ($wpmail) {
wp_mail($adminmail, $subject, $reportmail, $headers);
} else {
mail($adminmail, $subject, $reportmail, $headers);
}
}
}
}