Message is missing senders address

php, sendmail

Solution

You are escaping the double quote in headers, when it does not need to be escaped which will lead to you having two double quotes. Change your code to

$headers = 'From: ' .$email . "\r\n". 
  'Reply-To: ' . $email. "\r\n" . 
  'X-Mailer: PHP/' . phpversion();

mail($email_to, $subject, $message, $headers);

Problem

I am making a contact for a website and I am having issues. I am testing with XAMPP currently, using it's sendmail. I keep getting the error: Message is missing sender's address Here is the PHP Header Code: ``` //email headers $headers = 'From: \""' .$email . '\r\n'. 'Reply-To' . $email. "\r\n" . 'X-Mailer: PHP/' . phpversion(); mail($email_to, $subject, $message, $headers); ``` I can't figure out the issue. Thanks

Original source

Related problems