Forum Moderators: coopster
<?php
$to = "email@example.com";
$subject = "Test Email";
$headers = "From: noreply@mydomain.com\r\n";
$headers .= "Reply-To: noreply@mydomain.com\r\n";
$headers .= "Return-Path: noreply@mydomain.com\r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n";
$message = "<h1 style='font-family:Helvetica,Arial;font-size:16px'>Hi There</h1><p>This is a test!</p>";
if ( mail($to,$subject,$message,$headers) ) {
echo "The email has been sent!";
} else {
echo "The email has failed!";
}
?>