Skip to content

s2_email_subject

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

this hook allows the email subject to be changed at the point of sending. This is a global filter affecting all emails sent by Subscribe2 so you will probably want to do some string checks before making changes.

function my_email_subject($subject) {
if ( strstr($subject, 'Digest') ) {
$subject = 'My Preferred Email Subject for Digest Emails';
}
return $subject;
}
add_filter('s2_email_subject', 'my_email_subject');

Last updated on

Filed under Hooks, API & Customization

Still stuck?

Our support team can walk you through it.