title: Not receiving email from PHP mail() contact form
body: <p>I know this question has been asked countless times but I have been unable to find an answer specific to me.</p>
  
  <p>My contact form seems to be validating perfectly fine and when suitable data is entered and the "send message" button is clicked, a message is displayed saying the message has in fact been sent. There are no error messages on screen. </p>
  
  <p><strong>My html code looks like this:</strong></p>
  
  <pre><code>&lt;form action="send.php" id="contact_form" method="post" name="contact_form"&gt;
    &lt;ul&gt;
      &lt;li&gt;
        &lt;label&gt;NAME &lt;span class="required"&gt;*&lt;/span&gt;&lt;/label&gt;
        &lt;input type="text" name="name" id="name" value="" class="requiredField" /&gt;
      &lt;/li&gt;
      &lt;li&gt;
        &lt;label&gt;EMAIL &lt;span class="required"&gt;*&lt;/span&gt;&lt;/label&gt;
        &lt;input type="text" name="email" id="email" value="" class="requiredField email" /&gt;
      &lt;/li&gt;
      &lt;li class="textarea"&gt;
        &lt;label&gt;MESSAGE &lt;span class="required"&gt;*&lt;/span&gt;&lt;/label&gt;
        &lt;textarea name="message" id="message" rows="20" cols="30" class="requiredField"&gt;&lt;/textarea&gt;
      &lt;/li&gt;
      &lt;li class="button_form"&gt;
        &lt;input name="submitted" id="submitted" value="Send Message" class="submit" type="submit" /&gt;
        &lt;input id="reset" type="reset" value="Reset Form" class="submit" /&gt;
      &lt;/li&gt;
    &lt;/ul&gt;
  &lt;/form&gt;
  &lt;script type="text/javascript"&gt;
    //&lt;![CDATA[
    $(document).ready(function(){
      $("#form").validate();
    });
    //]]&gt;
  </code></pre>
  
  <p><strong>My JS looks like this:</strong></p>
  
  <pre><code>$(document).ready(function() {
    $('form#contact_form').submit(function() {
      $('form#contact_form .error').remove();
        var hasError = false;
        $('.requiredField').each(function() {
          if(jQuery.trim($(this).val()) == '') {
            var labelText = $(this).prev('label').text();
            $(this).parent().append('&lt;span class="error"&gt;Please enter your '+labelText+'&lt;/span&gt;');
            $(this).addClass('inputError');
            hasError = true;
          }
          else if($(this).hasClass('email')) {
            var emailReg = /^([\w-\.]+@([\w-]+\.)+[\w-]{2,4})?$/;
            if(!emailReg.test(jQuery.trim($(this).val()))) {
              var labelText = $(this).prev('label').text();
      $(this).parent().append('&lt;span class="error"&gt;Please a valid '+labelText+'&lt;/span&gt;');
              $(this).addClass('inputError');
              hasError = true;
            }
          }
        });
  
        if(!hasError) {
          $('form#contact_form input.submit').fadeOut('normal', function() {
            $(this).parent().append('');
          });
          var formInput = $(this).serialize();
          $.post($(this).attr('action'),formInput, function(data){
          $('form#contact_form').slideUp("fast", function() {
        $(this).before('&lt;p class="success"&gt;Thank you!&lt;br/&gt;Your email was sent successfully.&lt;br/&gt;I will contact you as soon as possible.&lt;/p&gt;');
          });
        });
      }
  
      return false;
    });
  });
  </code></pre>
  
  <p><strong>My PHP looks like this:</strong></p>
  
  <pre><code>&lt;?php 
  error_reporting(E_ALL ^ E_NOTICE); // hide all basic notices from PHP
  
  if(!isset($hasError)) {
  
    $emailTo = 'name@domain.com';
    $subject = 'Submitted message from '.$name;
    $sendCopy = trim($_POST['sendCopy']);
    $body = "Name: $name \n\nEmail: $email \n\nComments: $comments";
    $headers = 'From: ' .' &lt;'.$emailTo.'&gt;' . "\r\n" . 'Reply-To: ' . $email;
  
    mail($emailTo, $subject, $body, $headers);
  
  
    $emailSent = true;
  }
  }
  ?&gt;
  </code></pre>
  
  <p>Am i missing something in the code? Any help would be much appreciated!</p>