\Horde_Mime_Mdn

Message Disposition Notifications (RFC 3798).

Summary

Methods
Properties
Constants
__construct()
getMdnReturnAddr()
userConfirmationNeeded()
originalMessageText()
generate()
addMdnRequestHeaders()
No public properties found
MDN_HEADER
No protected methods found
$_headers
$_msgtext
N/A
No private methods found
No private properties found
N/A

Constants

MDN_HEADER

MDN_HEADER

Properties

$_headers

$_headers : \Horde_Mime_Headers

The Horde_Mime_Headers object.

Type

\Horde_Mime_Headers

$_msgtext

$_msgtext : string

The text of the original message.

Type

string

Methods

__construct()

__construct(\Horde_Mime_Headers  $headers) 

Constructor.

Parameters

\Horde_Mime_Headers $headers

getMdnReturnAddr()

getMdnReturnAddr() : string

Returns the address(es) to return the MDN to.

Returns

string —

The address(es) to send the MDN to. Returns null if no MDN is requested.

userConfirmationNeeded()

userConfirmationNeeded() : boolean

Is user input required to send the MDN? Explicit confirmation is needed in some cases to prevent mail loops and the use of MDNs for mail bombing.

Returns

boolean —

Is explicit user input required to send the MDN?

originalMessageText()

originalMessageText(string  $text) 

When generating the MDN, should we return the enitre text of the original message? The default is no - we only return the headers of the original message. If the text is passed in via this method, we will return the entire message.

Parameters

string $text

The text of the original message.

generate()

generate(boolean  $action, boolean  $sending, string  $type, string  $name, \Horde_Mail_Transport  $mailer, array  $opts = array(), array  $mod = array(), array  $err = array()) 

Generate the MDN according to the specifications listed in RFC 3798 [3].

Parameters

boolean $action

Was this MDN type a result of a manual action on part of the user?

boolean $sending

Was this MDN sent as a result of a manual action on part of the user?

string $type

The type of action performed by the user. Per RFC 3798 [3.2.6.2] the following types are valid:

  • deleted
  • displayed
string $name

The name of the local server.

\Horde_Mail_Transport $mailer

Mail transport object.

array $opts

Additional options:

  • charset: (string) Default charset. DEFAULT: NONE
  • from_addr: (string) From address. DEFAULT: NONE
array $mod

The list of modifications. Per RFC 3798 [3.2.6.3] the following modifications are valid:

  • error
array $err

If $mod is 'error', the additional information to provide. Key is the type of modification, value is the text.

addMdnRequestHeaders()

addMdnRequestHeaders(mixed  $to) 

Add a MDN (read receipt) request header.

Parameters

mixed $to

The address(es) the receipt should be mailed to.