回复won';t处理php表单提交给自己


Reply to won't work on php form submitting to itself

我无法获得回复函数来处理提交给自己的联系人表单。

BCC运行良好。感谢您的帮助。

$to = 'email@email.com';  
$subject = ''.$_POST['emailsubject'].''; 

$headers .= 'MIME-Version: 1.0' . "'r'n";
$headers .= 'Content-type: text/html; charset=iso-8859-1';
$headers .=  'Reply-To: '.$_POST['email'].''; 
'X-Mailer: PHP/' . phpversion();
$headers .= 'Bcc: email@email.com' . "'r'n";

mail($to, $subject, $msg, $headers); $sendMessage = true; unset($_POST); } } ?> <?php if($invalidCaptcha) { ?>
<?php
    $from_add = "test@gmail.com"; 
    $to_add = "email@email.com";
    $subject = "Test Msg";
    $message="test msg.";
    $headers = "From: $from_add 'r'n";
    $headers .= "Reply-To: $from_add 'r'n";
    $headers .= "Return-Path: $from_add'r'n";
    $headers .= "X-Mailer: PHP 'r'n";
if(mail($to_add,$subject,$message,$headers)) 
    {
        $msg = "Mail sent OK";
    } 
    else 
    {
       $msg = "Error sending email!";
    }   
?>