I have been sending a lot of HTML mail out of TYPO3 lately so thought I would paste the script here for future reference and use of anyone else wishing to use the script.
$Typo3_htmlmail = t3lib_div::makeInstance('t3lib_htmlmail');
$Typo3_htmlmail->start();
$Typo3_htmlmail->subject = 'Subject';
$Typo3_htmlmail->from_email = 'email@from.com';
$Typo3_htmlmail->returnPath = 'email@return.com';
$Typo3_htmlmail->from_name = 'sender';
$userMail = 'CONTENTS';
$userMail = '<html><head></head><body>'.$userMail.'</body></html>';
$Typo3_htmlmail->setRecipient(email@recipient.com);
$Typo3_htmlmail->setHTML($Typo3_htmlmail->encodeMsg($userMail));
$Typo3_htmlmail->addPlain(strip_tags($userMail, "<a>"));
$Typo3_htmlmail->send('');
this site was made by gamereaction
powered by TYPO3
RSS Feed
No comments have been posted