Skip to content

s2_public_subscriber_format

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

This hook is available in Subscribe2 HTML only. It allows the email type of Public Subscribers to be changed. By default in Subscribe2 HTML the email type is full content HTML, in the free version of Subscribe2 is it a plain text excerpt. Using this hook the email type can be specified at site level.

function my_preferred_format() {
// return one of the possible email types:
// 'html_body' for a full content HTML email
// 'html_excerpt_body' for an excerpt in HTML format
// 'plain_body' for a full content plain text email
// 'plain_excerpt_body' for an excerpt in plain text format
return 'html_excerpt_body';
}
add_filter('s2_public_subscriber_format', 'my_preferred_format');

Last updated on

Filed under Hooks, API & Customization

Still stuck?

Our support team can walk you through it.