Filter
rpress_receipt_headers
On this page
Filters the headers of the customer order email.
Runs just before the customer receipt is sent. The value is the header string built by the emails class, including From, Reply-To and Content-Type. The test receipt passes an order ID of 0 and an empty data array.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$headers | string | Email headers as returned by RPRESS_Emails::get_headers(). |
$payment_id | int | ID of the order, or 0 for the test receipt. |
$payment_data | array | Order meta from _rpress_payment_meta, or an empty array for the test receipt. |
Return value#
string. The email headers.
Example#
function my_receipt_headers( $headers, $payment_id, $payment_data ) {
return $headers . "Bcc: archive@example.com\r\n";
}
add_filter( 'rpress_receipt_headers', 'my_receipt_headers', 10, 3 );
Notes#
Header lines must end with a CRLF sequence to be valid.
Source#
Applied in:
includes/emails/functions.php(line 59), inrpress_email_purchase_receipt()includes/emails/functions.php(line 88), inrpress_email_test_purchase_receipt()
See also#
Was this page helpful?
