$_headers
$_headers : \Horde_Mime_Headers
The message headers.
The Horde_Mime_Mail:: class wraps around the various MIME library classes to provide a simple interface for creating and sending MIME messages.
All content has to be passed UTF-8 encoded. The charset parameters is used for the generated message only.
$_headers : \Horde_Mime_Headers
The message headers.
$_base : \Horde_Mime_Part
The base MIME part.
$_body : \Horde_Mime_Part
The main body part.
$_htmlBody : \Horde_Mime_Part
The main HTML body part.
addHeader(string $header, string $value, boolean $overwrite = null)
Adds a message header.
string | $header | The header name. |
string | $value | The header value. |
boolean | $overwrite | If true, an existing header of the same name is being overwritten; if false, multiple headers are added; if null, the correct behaviour is automatically chosen depending on the header name. |
addHeaderOb(\Horde_Mime_Headers_Element $ob)
Add a Horde_Mime_Headers_Element object to the current header list.
\Horde_Mime_Headers_Element | $ob | Header object to add. |
setBody(string $body, string $charset = null, boolean|integer $wrap = false)
Sets the message body text.
string | $body | The message content. |
string | $charset | The character set of the message. |
boolean|integer | $wrap | If true, wrap the message at column 76; If an integer wrap the message at that column. Don't use wrapping if sending flowed messages. |
setHtmlBody(string $body, string $charset = null, boolean $alternative = true)
Sets the HTML message body text.
string | $body | The message content. |
string | $charset | The character set of the message. |
boolean | $alternative | If true, a multipart/alternative message is created and the text/plain part is generated automatically. If false, a text/html message is generated. |
addPart(string $mime_type, string $content, string $charset = 'us-ascii', string $disposition = null) : integer
Adds a message part.
string | $mime_type | The content type of the part. |
string | $content | The content of the part. |
string | $charset | The character set of the part. |
string | $disposition | The content disposition of the part. |
The part number.
addMimePart(\Horde_Mime_Part $part) : integer
Adds a MIME message part.
\Horde_Mime_Part | $part | A Horde_Mime_Part object. |
The part number.
setBasePart(\Horde_Mime_Part $part)
Sets the base MIME part.
If the base part is set, any text bodies will be ignored when building the message.
\Horde_Mime_Part | $part | A Horde_Mime_Part object. |
addAttachment(string $file, string $name = null, string $type = null, string $charset = 'us-ascii') : integer
Adds an attachment.
string | $file | The path to the file. |
string | $name | The file name to use for the attachment. |
string | $type | The content type of the file. |
string | $charset | The character set of the part (only relevant for text parts. |
The part number.
send(\Mail $mailer, boolean $resend = false, boolean $flowed = true)
Sends this message.
$mailer | A Mail object. |
|
boolean | $resend | If true, the message id and date are re-used; If false, they will be updated. |
boolean | $flowed | Send message in flowed text format. |
getBasePart() : \Horde_Mime_Part
Return the base MIME part.