wc_mail( mixed $to, mixed $subject, mixed $message, string $headers = "Content-Type: text/htmlrn", string $attachments = '' )
Send HTML emails from WooCommerce.
Description Description
Parameters Parameters
- $to
-
(Required) Receiver.
- $subject
-
(Required) Subject.
- $message
-
(Required) Message.
- $headers
-
(Optional) Headers. (default: "Content-Type: text/htmlrn").
Default value: "Content-Type: text/htmlrn"
- $attachments
-
(Optional) Attachments. (default: "").
Default value: ''
Return Return
(bool)
Source Source
File: includes/wc-core-functions.php
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 ); }