◀ Previous Next ▶ Up ▲



ส่งเมล์เป็น html แล้วมีปัญหาคับ

$email = "[email protected], [email protected]";
$invoicetotal = "TEST";

# -=-=-=- MIME BOUNDARY

$mime_boundary = "----Your_Company_Name----".md5(time());

# -=-=-=- MAIL HEADERS

$to = $email;
$subject = "ทดสอบ";

$headers = "From: [email protected]\n";
$headers .= "Reply-To: [email protected]\n";
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-Type: multipart/alternative; boundary=\"$mime_boundary\"\n";

# -=-=-=- TEXT EMAIL PART

$message = "--$mime_boundary\n";
$message .= "Content-Type: text/plain; charset=TIS-620\n";
$message .= "Content-Transfer-Encoding: 8bit\n";

$message .= "\n\n";
$message .= "This email is to confirm that received your order.\n";
$message .= "Please send payment of $invoicetotal to our company address.\n\n";
$message .= "Thank You.\n\n";

# -=-=-=- HTML EMAIL PART

$message .= "--$mime_boundary\n";
$message .= "Content-Type: text/html; charset=TIS-620\n";
$message .= "Content-Transfer-Encoding: 8bit\n\n";

$message .= $html;
$err=mail($to,$subject,$message,$headers);

แต่พอผม mark ช่วงนี้ไว้
$message .= "This email is to confirm that received your order.\n";
$message .= "Please send payment of $invoicetotal to our company address.\n\n";
$message .= "Thank You.\n\n";

พอส่งเมล์ไปจะรับไม่ได้เลย
ไม่ขึ้น error อะไรเลยด้วยคับ


จากคุณ : golf_mc1 -[ 13 มิ.ย. 50 - 14:42:08 ]





กระทู้ยอดนิยม