Property | Type | Description | |
---|---|---|---|
$content | string | The email body content. | |
$headers | array | Email headers of the current email. | |
$is_html | boolean | Whether the current email uses HTML exclusively. | |
$querystring | string | The querystring parsed from the 'From' email address. | |
$subject | string | The email subject line. | |
$user | object | The WP_User object when successfully parsed. |
Method | Description | |
---|---|---|
__construct ( array $args = [], $i = 1 ) | Constructor. | |
get_body ( string $body = '', boolean $html = false, boolean $reply = true, integer $i = 1 ) : string | boolean | Parses and returns the email body content. | |
get_header ( array | object $headers, string $key ) : mixed | Returns an email header. | |
get_querystring ( string $address = '' ) : mixed | Returns the querystring from an email address. | |
init ( $args = [], $i = 1 ) : array | object | Static initializer. | |
validate_headers ( array $headers = [], integer $i ) : mixed | Checks email headers for auto-submitted / auto-replies. |
Method | Description | |
---|---|---|
clear_properties ( ) | Clears static properties after reaching the end of parsing. | |
get_parameters ( ) : mixed | Decodes the encoded querystring from {@link BP_Reply_By_Email_Parser::get_querystring()}. | |
is_new_item ( ) : boolean | Check to see if we're parsing a new item (like a new forum topic). |
public __construct ( array $args = [], $i = 1 ) | ||
$args | array | { An array of arguments. @type array $headers Email headers. @type string $to_email The 'To' email address. @type string $from_email The 'From' email address. @type string $content The email body content. @type string $subject The email subject line. @type bool $html Whether the email content is HTML or not. } |
protected static clear_properties ( ) |
public static get_body ( string $body = '', boolean $html = false, boolean $reply = true, integer $i = 1 ) : string | boolean | ||
$body | string | The email body content. |
$html | boolean | Whether the email body is HTML or not. Defaults to false. |
$reply | boolean | Whether the current item is a reply. Defaults to true. |
$i | integer | The current email message number. |
return | string | boolean |
protected static get_parameters ( ) : mixed | ||
return | mixed | Either an array of params on success or false on failure |
public static get_querystring ( string $address = '' ) : mixed | ||
$address | string | The email address containing the address tag |
return | mixed | Either the address tag on success or false on failure |
protected static is_new_item ( ) : boolean | ||
return | boolean |
public static array $headers | ||
return | array |
public static bool $is_html | ||
return | boolean |
public static string $querystring | ||
return | string |
public static object $user | ||
return | object |