Skip to content

Instantly share code, notes, and snippets.

@tommcfarlin
Last active December 12, 2016 15:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tommcfarlin/6c9a32045e50257bc962efe6236c84c1 to your computer and use it in GitHub Desktop.
Save tommcfarlin/6c9a32045e50257bc962efe6236c84c1 to your computer and use it in GitHub Desktop.
[WordPress] Customizing WooCommerce Emails
<?php
add_action( 'woocommerce_email_before_order_table', 'acme_email_message', 20 );
/**
* Adds a single line above the table of purchases in a WooCommerce email.
*/
function acme_email_message() {
$html = '<p>';
$html .= 'Access your additional information on your My Account page.';
$html .= '</p>';
$allowed_html = array(
'p' => array(),
);
echo wp_kses( $html, $allowed_html );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment