<html>

<head>
    <title>PHPMailer Pro - SMTP (minimal)</title>
</head>

<body>
    <?php
                /*
     * This test designed for PHPMailer Pro version 2024.1.2.1 and up ...
     */
    // There are a number of ways to test your scripts. One of those is
// aboutmy.email test service ...
// if you prefer NOT to use a test service, please change
// the email addresses as you would like them to be for your tests
    
    require_once('assets/lib/PHPMailer.Pro.php');
    class_alias("codeworxtech\PHPMailerPro\PHPMailerPro", "PHPMailerPro");

    $mail = new PHPMailerPro();

    $mail->AddRecipient(['recipient@example.com' => 'Recipient Name']);
    $mail->subject = "PHPMailer Pro Sendmail minimal test";
    $mail->messageHTML = "<p>Test HTML message, minimal configuration.</p>";

    if ($mail->Send('sendmail')) { //choose Sendmail as transport method
        echo "Email sent successfully.<br>";
    } else {
        echo "Oops! Error sending email.<br>";
    }

    
    ?>
</body>

</html>