2017 © Pedro Peláez
 

library zf2mail

ZF2-Mail is very simple ZF2 module for handling ZF2 mails.

image

arvind2110/zf2mail

ZF2-Mail is very simple ZF2 module for handling ZF2 mails.

  • Tuesday, June 24, 2014
  • by arvind2110
  • Repository
  • 1 Watchers
  • 2 Stars
  • 48 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

ZF2Mail

ZF2-Mail is a simple ZF2 module to implement and manage mail functionality in ZF2 applications., (*1)

SMTP settings : module.config.php, (*2)

return array(
    "EMAIL" => array(
        "SMTP_SENDER_TYPE" => "user",
        "SMTP_NAME" => "localhost",
        "SMTP_HOST" => "localhost",
        "SMTP_PORT" => "25",
        "SMTP_CONNECTION_CLASS" => "plain",
        "SMTP_USERNAME" => "",
        "SMTP_PASSWORD" => "",
        "SMTP_SSL" => "",
        "BODY" => "Custom default message",
        "FROM" => "noreply@example.com",
        "TO" => "yoremail@example.com",
        "MAIL_FROM_NICK_NAME" => "Custom Name",
        "SUBJECT" => "Custom Subject",
        "FROM_NICK_NAME" => "Cutom From",
        "EMAIL_TEMPLATE_PATH" => __DIR__ . "/../view/emails/templates/",
        "USE_SMTP" => FALSE
    )    
);

Sending Mails, (*3)


$mail = $this->getServiceLocator()->get('ZF2Mail'); $mailOptions = array( 'mailTo' => 'arvind.singh.2110@gmail.com', 'mailFrom' => 'example@example.com', 'mailSubject' => 'My Custom Subject', 'mailBody' => 'My custom message', 'templateFile' => 'custom-message', 'params' => array('name' => 'Arvind Singh') ); $mail->sendMail($mailOptions);

You can pass other parameters as per your requirement., (*4)

The Versions

24/06 2014

dev-master

9999999-dev https://github.com/arvind2110/ZF2Mail

ZF2-Mail is very simple ZF2 module for handling ZF2 mails.

  Sources   Download

The Requires

  • php >=5.3

 

mail zf2 zf2 mail