title: What is the right way to send PHP Mail Headers?
body: <p>I have run into a weird problem. Some clients would like to be able to use gmail canned responses with emails submitted through their site's web form. Up until canned responses, everything has worked fine. Simply clicking "reply" on an email from the web form submission worked like a charm and replied to the sender. However, CannedResponses from Google Labs is proving to be a problem. Canned responses is auto replying to <code>myUsername@myWebserver.com</code> (changed for privacy reasons, obviously) rather than the senders email address. Am I doing something wrong with the headers, or is there another workaround? Code below:</p>
  
  <pre><code>function send_mail($to, $subject, $from, $messageData=array()) {
  
      // Build the message here
  
      $mailheaders = "From: $from";
      $mailheaders .= "\r\n";
      $mailheaders .= "Reply-To: $from";
  
      return mail($to, $subject, $message, $mailheaders);
  }
  </code></pre>
  
  <p><strong>Edit for clarification:</strong>
  What I mean by auto replies being sent to <code>myUsername@myWebserver.com</code> is my username <code>at</code> my dreamhost web server - ps0000.dreamhostps.com</p>