I’ve been trying out the PHPMailer sample script as given in its README file. Now, when I run that script:
<?php
require("phpmailer.inc.php");
$mail = new phpmailer;
//$mail->IsSMTP(); // set mailer to use SMTP
$mail->From = "from@email.com";
$mail->FromName = "Mailer";
//$mail->Host = "smtp1.site.com;smtp2.site.com"; // specify main and backup server
$mail->AddAddress("someone@someplace.com");
//$mail->AddAddress("ellen@site.com"); // name is optional
$mail->AddReplyTo("info@site.com", "Information");
$mail->WordWrap = 50; // set word wrap
//$mail->AddAttachment("c:\\temp\\js-bak.sql"); // add attachments
//$mail->AddAttachment("c:/temp/11-10-00.zip");
$mail->IsHTML(true); // set email format to HTML
$mail->Subject = "Here is the subject";
$mail->Body = "This is the message body";
$mail->Send(); // send message
?>
I get the following warning :
Warning: mb_send_mail() [function.mb-send-mail]: Unsupported charset
“”iso-8859-1″;” – will be regarded as ascii in
/export/opt/samplefiles/phpmailer.inc.php on line 162
and the message that is received contains the header as well:
Mime-Version: 1.0 This is the message body
Please help
I just realized that I’ve actually been using an older version of PHPMailer (version 0.89 or something). I’ve gotten myself a newer 5.2 and it appears resolved. Thanks anyway 😛