<?php
require ("mimemail.inc.php");
///If you have'nt downloaded SMTP class required in mimemail class then
// just comment the require file and uncomment the php mail function in send function in class.
//
$fp=fopen("mimemail.inc.php","r");
$data=fread($fp,filesize("mimemail.inc.php"));
fclose($fp);
$mail=new MIMEMAIL();
$mail->from="HARISH<harishc@templatearena.com>";
$mail->to="harish<harishc@templatearena.com>";
$mail->cc="Tapan<tapank@templatearena.com>;manoj<manojk@templatearena.com>";
$mail->subject="welcome";
$mail->body="<b>This is test mail.don't reply it.</b>";
$mail->html=true;
$mail->add_attachment($data,"mimemail.inc.php" ,"application/octet-stream" );
if(!$mail->send())
echo "Error in sending mail!";
else
echo "Mail sent succesfully!";
?>
|