Use this package to integrate PHPMailer with your project built on top of Koldy Framework. Minimum PHP version is PHP 8.1. This package is using PHPMailer to send emails via SMTP only.
composer require koldy/phpmailerIn your project's config folder (usually configs/mail.php), add the following block:
'phpmailer' => [
'enabled' => true,
'adapter_class' => \KoldyPHPMailer\PHPMailer::class,
'options' => [
'host' => 'your.domain.com', // required
'port' => 465, // required
'username' => 'your.username', // optional
'password' => 'your.password', // optional
'from' => 'no-reply@your.domain.com', // optional
'fromName' => 'Your Name', // optional
'adjust' => function ($phpmailer) { // optional
// you can adjust the PHPMailer's instance here, for example:
$phpmailer->SMTPDebug = \PHPMailer\PHPMailer\SMTP::DEBUG_SERVER;
}
]
]Open sourced and published under MIT licence.