Skip to content

s2_html_email s2_plain_email s2_digest_email

  • Subscribe2
  • Updated Nov 23, 2023
  • 1 min read

These hooks allow the entire content of the email to be filter and amended immediately prior to sending. An example use for the ‘s2_html_email’ hook to add a stylesheet is below.

function my_s2html_filter($message) {
if ( empty($message) ) { return; }
list($first, $second) = explode('', $message, 2);
$message = $first . '' . $second;
return $message;
}
add_filter('s2_html_email', 'my_s2html_filter');

Last updated on

Filed under Hooks, API & Customization

Still stuck?

Our support team can walk you through it.