Skip to content

daemionfox/Mailer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

81 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mailer Build Status

A lightweight SMTP mail sender

Install

$ composer require txthinking/mailer

Usage

<?php
use Tx\Mailer;

$ok = (new Mailer())
    ->setServer('smtp.server.com', 25)
    ->setAuth('[email protected]', 'password')
    ->setFrom('Tom', '[email protected]')
    ->setFakeFrom('Obama', '[email protected]') // if u want, a fake name, a fake email
    ->addTo('Jerry', '[email protected]')
    ->setSubject('Hello')
    ->setBody('Hi, Jerry! I <strong>love</strong> you.')
    ->addAttachment('host', '/etc/hosts')
    ->send();
var_dump($ok);

More Example

About

A lightweight PHP SMTP mail sender

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%