1. Go to this page and download the library: Download brbunny/brmailer library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
BrBunny\BrMailer\BrMailer;
$email = new BrMailer();
// (string Subject, string Body, string RecipientAddress, string RecipientName)
$email->bootstrap(
"Here is the subject",
"This is the message body",
"[email protected]", // E-mail is Optional
"Van User" // Name is Optional
);
$template = $email->template("./theme")->renderTemplate("_theme", [
"title" => "E-mail",
"company" => "BrBunny"
]);
$email->bootstrap(
"Here is the subject",
$template
);