s2_html_email

The Subscribe2 s2 html email hook.

Description

Parameters (3)

0. $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html — Optional. (string) => "" . $subject . "" . $message . ""
The html head title subject title link rel stylesheet href get stylesheet uri type text css media screen head body message body html.
1. $subject (unknown)
The subject.
2. $message (unknown)
The message.

Usage

To run the hook, copy the example below.
  1. $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html = apply_filters( 's2_html_email', $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html, $subject, $message ); 
  2.  
  3. if ( !empty( $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the s2_html_email callback 
  2. function filter_s2_html_email( $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html, $subject, $message ) { 
  3. // make filter magic happen here... 
  4. return $html_head_title_subject_title_link_rel_stylesheet_href_get_stylesheet_uri_type_text_css_media_screen_head_body_message_body_html
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 's2_html_email', 'filter_s2_html_email', 10, 3 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 's2_html_email', 'filter_s2_html_email', 10, 3 ); 

Defined (2)

The filter is defined in the following location(s).

/classes/class-s2-core.php  
  1. $mailtext = apply_filters('s2_html_email', "<html><head><title>" . $subject . "</title><link rel=\"stylesheet\" href=\"" . get_stylesheet_uri() . "\" type=\"text/css\" media=\"screen\" /></head><body>" . $message . "</body></html>", $subject, $message); 
  1. $mailtext = apply_filters('s2_html_email', "<html><head><title>" . $subject . "</title></head><body>" . $message . "</body></html>", $subject, $message);