I am working on a service that sends emails from AWS SES. I could send plain text letters, but I need to send rich HTML letters in one of the cases. This is the code I'm using:
header("MIME-Version: 1.0; Content-type: text/html; charset=iso-8859-1"); require_once(dirname(__FILE__).'/AWSSDKforPHP/sdk.class.php'); // Instantiate the Amazon class $ses = new AmazonSES(); $source = ' abc@www..com '; $dest = array('ToAddresses'=>array($to)); $message = CFComplexType::map(array('Subject.Data'=>$subject, 'Body.Html.Data'=>$message_mail)); $rSendEmail = $ses->send_email($source, $dest, $message);
message_mail is some HTML text placed inside tables. I tried both send_email and send_raw_email, but both of them did not work. Do I need to do something extra or something else?
source share