Coding

How To Send HTML Format Email in PHP

Welcome to zaiygam.com, I will cover in this article which will show you how to send HTML format email using PHP, normally PHP send plain text email it’s can’t send any formatting or graphics by default so, send the email with HTML it’s the best way to send formatting email so let’s start this article.

//Send HTML Email Using PHP

$to="username@example.com";
//subject of the mail
$subject = "Test Email";

//message of the mail which contains some html
$message =”

Name Email
Test1 test1@google.com
Test2 test2@yahoo.com
Test3 test3@gmail.com

“;

$headers .= “From:noreply@zaiygam.com”;
$headers .= “Content-type: text/html; charset=iso-8859-1rn”;
mail($to, $subject, $message, $headers);
echo $message;
?>

I hope you like my post and don’t forget to share with your colleagues on facebook or twitter or GitHub!!!!

Zaiygam

Hey, As a content publisher here, we share the knowledge and experience which we gain in day-to-day life. Thanks for visiting the site.

Leave a Reply

Your email address will not be published.

Back to top button
GDFXXNNB62199330

Adblock Extension or Add on Detected

Please consider supporting us by disabling your ad blocker