PHP code example of phphleb / muller
1. Go to this page and download the library: Download phphleb/muller 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/ */
phphleb / muller example snippets
// Include or autoload
tory>/phphleb/muller/Src/Errors.php';
nding to multiple destinations
$mail->setNameFrom('User Name');
$mail->setAddressFrom('[email protected]');
$mail->setParameters('[email protected]');
$mail->setTitle('Verification letter');
$mail->setDebug(true);
$mail->setDebugPath('<storage directory>/logs');
$mail->saveOnlyToFile(false);
$mail->saveFileIntoDirectory('<storage directory>/logs');
$mail->setTo('[email protected]');
$mail->setTo('[email protected]', 'Recipient 2');
$mail->setToMultiple(['[email protected]' => 'Recipient 3', '[email protected]' => 'Recipient 4']);
$mail->setContent('
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<body style="margin: 0; padding: 0; background-color: #E1D2C1; color: #000000">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td>
Test letter text.
</td>
</tr>
</table>
</body>
</html>
');
$mail->send();
var_dump($mail->getErrors());