$rcpts = array(array('name' => 'Test Smith', 'email' => '*****@*****.**'), array('name' => 'Someone Else', 'email' => '*****@*****.**'));
$html = <<<HTMLMSG
<html>
<head>
<title>
Test HTML Email
</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body>
<h1>Hello [{name}]</h1>
<p>
I'm just trying out this new Pop Mail Library component.
</p>
<p>
Thanks,<br />
Bob
</p>
</body>
</html>
HTMLMSG;
$mail = new Mail('Hello World!', $rcpts);
$mail->from('*****@*****.**', 'Bob')->setHeaders(array('X-Mailer' => 'PHP/' . phpversion(), 'X-Priority' => '3'));
$mail->setText("Hello [{name}],\n\nI'm just trying out this new Pop Mail component.\n\nThanks,\nBob\n\n");
$mail->setHtml($html);
$mail->send();
echo 'Mail Sent!';
} catch (\Exception $e) {
echo $e->getMessage();
}