Toan Tran Van
Toan Tran Van

Reputation: 759

Need help to send email with PHPMailer

I'm using PHPMailer to send email. Everything is working fine except one thing. The email could not be send if the subject contains an UTF-8 character. I've set $mail->CharSet="UTF-8".

Upvotes: 1

Views: 1655

Answers (1)

nithi
nithi

Reputation: 3877

Try to encode subject to handle utf8 characters...

$sendsubject= "=?utf-8?b?".base64_encode($subject)."?=";
$mail = new PHPMailer();
$mail->Subject = $sendsubject;

Upvotes: 4

Related Questions