API Documentation

Mail/Transport/Abstract.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Mail
subpackage
Transport
version
$Id: Abstract.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Mail_Transport_Abstract

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Mail_Transport_Abstract

category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Mail
subpackage
Transport
Properties
$body
$boundary
$header
$_headers
$_isMultipart
$_mail
$_parts
$recipients
$EOL
Methods
_sendMail
_getHeaders
_formatHeader
_prepareHeaders
_buildBody
send

Description

Abstract for sending eMails through different ways of transport

Properties

$EOL

string $EOL = '\r\n'

EOL character string used by transport

Details

$EOL
string
visibility
public
default
\r\n
final
false
static
false
access
public

$_headers

array $_headers = 'array'

Array of message headers

Details

$_headers
array
visibility
protected
default
array
final
false
static
false
access
protected

$_isMultipart

boolean $_isMultipart = 'false'

Message is a multipart message

Details

$_isMultipart
boolean
visibility
protected
default
false
final
false
static
false
access
protected

$_mail

false|Zend_Mail $_mail = 'false'

Zend_Mail object

Details

$_mail
false|Zend_Mail
visibility
protected
default
false
final
false
static
false
access
protected

$_parts

array $_parts = 'array'

Array of message parts

Details

$_parts
array
visibility
protected
default
array
final
false
static
false
access
protected

$body

string $body = ''

Mail body

Details

$body
string
visibility
public
default
final
false
static
false
access
public

$boundary

string $boundary = ''

MIME boundary

Details

$boundary
string
visibility
public
default
final
false
static
false
access
public

$header

string $header = ''

Mail header string

Details

$header
string
visibility
public
default
final
false
static
false
access
public

$recipients

string $recipients = ''

Recipients string

Details

$recipients
string
visibility
public
default
final
false
static
false
access
public

Methods

_buildBody

_buildBody( ) : void

Generate MIME compliant message from the current configuration

If both a text and HTML body are present, generates a multipart/alternative Zend_Mime_Part containing the headers and contents of each. Otherwise, uses whichever of the text or HTML parts present.

The content part is then prepended to the list of Zend_Mime_Parts for this message.

Details
visibility
protected
final
false
static
false

_formatHeader

_formatHeader( string $item, string $key, string $prefix ) : void

Prepend header name to header value

Arguments
$item
string
$key
string
$prefix
string
Details
visibility
protected
final
false
static
true
access
protected
static

_getHeaders

_getHeaders( string $boundary ) : array

Return all mail headers as an array

If a boundary is given, a multipart header is generated with a Content-Type of either multipart/alternative or multipart/mixed depending on the mail parts present in the {@link $_mail Zend_Mail object} present.

Arguments
$boundary
string
Output
array
Details
visibility
protected
final
false
static
false

_prepareHeaders

_prepareHeaders( mixed $headers ) : void

Prepare header string for use in transport

Prepares and generates {@link $header} based on the headers provided.

Arguments
$headers
mixed
Details
visibility
protected
final
false
static
false
access
protected
throws
if any header lines exceed 998 characters

_sendMail

_sendMail( ) :

Send an email independent from the used transport

The requisite information for the email will be found in the following properties:

  • {@link $recipients} - list of recipients (string)
  • {@link $header} - message header
  • {@link $body} - message body
Details
visibility
protected
final
false
static
false

send

send( Zend_Mail $mail ) : void

Send a mail using this transport

Arguments
$mail
Zend_Mail
Details
visibility
public
final
false
static
false
access
public
throws
if mail is empty
Documentation was generated by DocBlox.