An open API service indexing awesome lists of open source software.

https://github.com/g4code/mailer


https://github.com/g4code/mailer

Last synced: 3 months ago
JSON representation

Awesome Lists containing this project

README

          

mailer
======

> mailer - [php](http://php.net) library

## Install
Via Composer

```sh
composer require g4/mailer
```

## Usage

```php
"smtp",
'adapter' => "smtp",
'params' => [
'host' => "smtp.example.com",
'port' => "587",
'connection_class' => "plain",
'connection_config' => [
'ssl' => "tls",
'username' => "smtp_username",
'password' => "smtp_password"
]
]
];

// Create message
$message = new \G4\Mailer\Message(
'receiver@example.com',
'sender@example.com',
'Email subject',
'This is a html email part',
'This is a text email part'
);

// Create mailer instance
$mailer = \G4\Mailer\Mailer::factory($options);

// send message
$mailer->send($message);

?>
```

## Development

### Install dependencies

$ make install

### Run tests

$ make test

## License

(The MIT License)
see LICENSE file for details...