drewlabs/envoyer-smtp
最新稳定版本:v0.2.2
Composer 安装命令:
composer require drewlabs/envoyer-smtp
包简介
SMTP drivers for envoyer client library
README 文档
README
SMTP drivers provide implementations of drewlabs/envoyer driver or client interface that uses smtp protocol internally to send text message to send email messages.
Usage
use Drewlabs\Envoyer\Drivers\Smtp\SymfonyMailerAdapter; use Drewlabs\Envoyer\Mail; use Drewlabs\Envoyer\SMTPServer; $config = require __DIR__ . '/contents/config.php'; // Create mail instance $mail = Mail::new() ->from($config['email']) ->to('azandrewdevelopper@gmail.com') ->subject('No Attachment Registration') ->content(require __DIR__ . '/contents/mail.php'); // Create SMTP server configuration object $smtpServer = new SMTPServer($config['host'], $config['port'], $config['user'], $config['password']); // Create Symfony mailer object $adapter = new SymfonyMailerAdapter($smtpServer->withEncryption('tls')); // Send mail request $result = $adapter->sendRequest($mail);
统计信息
- 总下载量: 72
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-06-21