Zend_Mail::_addRecipientAndHeader PHP Method

_addRecipientAndHeader() protected method

Helper function for adding a recipient and the corresponding header
protected _addRecipientAndHeader ( string $headerName, string $email, string $name )
$headerName string
$email string
$name string
    protected function _addRecipientAndHeader($headerName, $email, $name)
    {
        $email = $this->_filterEmail($email);
        $name = $this->_filterName($name);
        // prevent duplicates
        $this->_recipients[$email] = 1;
        $this->_storeHeader($headerName, $this->_formatAddress($email, $name), true);
    }

Usage Example

Example #1
0
 /**
  * Helper function for adding a recipient and the corresponding header
  *
  * @param string $headerName
  * @param string $email
  * @param string $name
  */
 protected function _addRecipientAndHeader($headerName, $email, $name)
 {
     $this->getLog()->addRecipient($headerName, $email, $this->_decodeBase64Header($name));
     parent::_addRecipientAndHeader($headerName, $email, $name);
 }