Class Zend_Mail_Transport_Smtp

Description

SMTP connection object

Loads an instance of Zend_Mail_Protocol_Smtp and forwards smtp transactions

  • copyright: Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  • license: New BSD License

Located in /Mail/Transport/Smtp.php (line 51)

Zend_Mail_Transport_Abstract
   |
   --Zend_Mail_Transport_Smtp
Variable Summary
 string $EOL
 string $_auth
 array $_config
 string $_host
 string $_name
 integer|null $_port
Method Summary
 void __construct ([string $host = '127.0.0.1'], [ $config = array()])
 void __destruct ()
 Zend_Mail_Protocol|null getConnection ()
 void _prepareHeaders (array $headers)
 void _sendMail ()
Variables
string $EOL = "\n" (line 58)

EOL character string used by transport

  • access: public

Redefinition of:
Zend_Mail_Transport_Abstract::$EOL
EOL character string used by transport
string $_auth (line 89)

Authentication type OPTIONAL

  • access: protected
array $_config (line 97)

Config options for authentication

  • access: protected
Zend_Mail_Protocol_Smtp $_connection (line 105)

Instance of Zend_Mail_Protocol_Smtp

  • access: protected
string $_host (line 65)

Remote smtp hostname or i.p.

  • access: protected
string $_name = 'localhost' (line 81)

Local client hostname or i.p.

  • access: protected
integer|null $_port (line 73)

Port number

  • access: protected

Inherited Variables

Inherited from Zend_Mail_Transport_Abstract

Zend_Mail_Transport_Abstract::$body
Zend_Mail_Transport_Abstract::$boundary
Zend_Mail_Transport_Abstract::$header
Zend_Mail_Transport_Abstract::$recipients
Zend_Mail_Transport_Abstract::$_headers
Zend_Mail_Transport_Abstract::$_isMultipart
Zend_Mail_Transport_Abstract::$_mail
Zend_Mail_Transport_Abstract::$_parts
Methods
Constructor __construct (line 118)

Constructor.

  • todo: Someone please make this compatible with the SendMail transport class.
  • access: public
void __construct ([string $host = '127.0.0.1'], [ $config = array()])
  • string $host: OPTIONAL (Default: 127.0.0.1)
  • array|null $config: OPTIONAL (Default: null)
Destructor __destruct (line 140)

Class destructor to ensure all open connections are closed

  • access: public
void __destruct ()
getConnection (line 171)

Gets the connection protocol instance

  • access: public
Zend_Mail_Protocol|null getConnection ()
setConnection (line 160)

Sets the connection protocol instance

  • access: public
void setConnection (Zend_Mail_Protocol_Abstract $connection, Zend_Mail_Protocol_Abstract $client)
_prepareHeaders (line 228)

Format and fix headers

Some SMTP servers do not strip BCC headers. Most clients do it themselves as do we.

  • throws: Zend_Transport_Exception
  • access: protected
void _prepareHeaders (array $headers)
  • array $headers

Redefinition of:
Zend_Mail_Transport_Abstract::_prepareHeaders()
Prepare header string for use in transport
_sendMail (line 185)

Send an email via the SMTP connection protocol

The connection via the protocol adapter is made just-in-time to allow a developer to add a custom adapter if required before mail is sent.

  • todo: Rename this to sendMail, it's a public method...
  • access: public
void _sendMail ()

Redefinition of:
Zend_Mail_Transport_Abstract::_sendMail()
Send an email independent from the used transport

Inherited Methods

Inherited From Zend_Mail_Transport_Abstract

 Zend_Mail_Transport_Abstract::send()
 Zend_Mail_Transport_Abstract::_buildBody()
 Zend_Mail_Transport_Abstract::_formatHeader()
 Zend_Mail_Transport_Abstract::_getHeaders()
 Zend_Mail_Transport_Abstract::_prepareHeaders()
 Zend_Mail_Transport_Abstract::_sendMail()

Documentation generated on Mon, 21 Jun 2010 15:45:24 -0400 by phpDocumentor 1.4.3