title: Basic PHP contact form issue
body: <p>Im trying to setup a basic PHP contact form and despite my best efforts I can't seem to make it work: </p>
  
  <p>on contact.php my code looks like this:</p>
  
  <pre><code>include_once('form_record.php');
  $obj = new formRECORD(); 
  if ( $_POST )
       $obj-&gt;send_mail($_POST);
  echo $obj-&gt;display_form();
  </code></pre>
  
  <p>And then form_record.php looks like this: </p>
  
  <pre><code>class formRECORD {
  
      public function display_form() {
      $entry_display .= &lt;&lt;&lt;ENTRY_DISPLAY
                 &lt;form &gt;
                 &lt;label&gt;Name&lt;/label&gt;&lt;br/&gt;
                 &lt;input id="form_name"&gt;&lt;br/&gt;
                 &lt;label&gt;Email&lt;/label&gt;&lt;br/&gt;
                 &lt;input id="form_email"&gt;&lt;br/&gt;
                 &lt;label&gt;Phone:&lt;/label&gt;&lt;br/&gt;
                 &lt;input id="form_phone"&gt;&lt;br/&gt;
                 &lt;label&gt;Name&lt;/label&gt;&lt;br/&gt;
                 &lt;textarea id="body"&gt;&lt;/textarea&gt;&lt;br/&gt;
                 &lt;input type="submit" value="Send" /&gt;
                 &lt;/form&gt;
  ENTRY_DISPLAY;
  
    return $entry_display;
  
  }
      public function send_mail($p) {
          $to = "example@gmail.com"; 
          $subject = "Contact Us"; 
          $email = $_POST['form_email'] ; 
          $message = $_POST['body'] ; 
          $headers = "From: $email"; $sent = mail($to, $subject, $message, $headers) ; 
          if($sent) {return "Your mail was sent successfully"; } else {return "We encountered an error sending your mail"; }
      }
  
  }
  </code></pre>
  
  <p>The contact form shows up OK and there aren't any php errors when the user hits submit. However the email never appears in my inbox. Any ideas?</p>