title: Mail function not working on online server
body: <p>i write a perfect code but i dont understand why my mail not send</p>
  
  <pre><code>$to = "info@domain.com";
      $subject = "Account request from $first_name $last_name";
      $emailBody = "
              hi,
              &lt;br /&gt;&lt;br /&gt;
              &lt;strong&gt;First Name&lt;/strong&gt; : $first_name.&lt;br /&gt;
              &lt;strong&gt;Last Name&lt;/strong&gt; : $last_name.&lt;br /&gt;
              &lt;strong&gt;Phone&lt;/strong&gt; : $phone.&lt;br /&gt;
              &lt;strong&gt;Email&lt;/strong&gt; : $email.&lt;br /&gt;
              &lt;strong&gt;Message&lt;/strong&gt; : $message.
      ";
  
      //  Email headers
      $headers = "MIME-Version: 1.0" . "\r\n";
      $headers .= "Content-type:text/html;charset=iso-8859-1" . "\r\n";
      $headers .= 'From: domain' . "\r\n";
  
      //  Email Function
      $mail = mail($to,$subject,$emailBody,$headers);
  </code></pre>
  
  <p>if i check in condtion</p>
  
  <pre><code>if($mail)
  {
  echo 'success';
  }
  else
  {
  echo 'fail';
  }
  </code></pre>
  
  <p>on Localhost it shows me success but on online server it shows me fail - idont understand why????</p>