wc_mail()
Send HTML emails from WooCommerce.
Хуков нет.
Возвращает
true|false
.
Использование
wc_mail( $to, $subject, $message, $headers, $attachments );
- $to(разное) (обязательный)
- Receiver.
- $subject(разное) (обязательный)
- Subject.
- $message(разное) (обязательный)
- Message.
- $headers(строка)
- Headers. ..
По умолчанию: "Content-Type: text/html\r\n" - $attachments(строка)
- Attachments. ..
По умолчанию: ""
Код wc_mail() wc mail WC 9.8.1
function wc_mail( $to, $subject, $message, $headers = "Content-Type: text/html\r\n", $attachments = '' ) { $mailer = WC()->mailer(); return $mailer->send( $to, $subject, $message, $headers, $attachments ); }