Amazon SES – Send HTML mail through PHP sdk

Amazon SES – Send HTML mail through PHP sdk

I am trying to send an email using amazon ses PHP sdk.

I got the following code. Working Fine

$body = "
<title>HTML email</title>
<p>This email contains HTML Tags!</p>

$ses = new SimpleEmailService('KEY', 'KEY');
$m = new SimpleEmailServiceMessage();
$m->addTo('[email protected]');
$m->setFrom('Test Support <[email protected]>');
$m->setSubject('Hello, world!');

This code pretty working well and I am confused how to send a HTML formatted mail through this script.

A body like this

$body='<div ><b>Name</b></div>';

Any one please help me
Thanks in advance

Ok think I have found the system you are using and it doesnt look like the standard SES api.



Where you have the plain text version and html version of your emails defined in $plainTextBody and $HTMLBody before that line.