title: how to fix mail(): SMTP server response: 550 5.5.0 Invalid EHLO/HELO domain error in php
body: <p>I'm trying to send an email through a html contact using php. I've done all the necessary php.ini settings and I'm still gettting this error.....=>mail(): SMTP server response: 550 5.5.0 Invalid EHLO/HELO domain. in C:\xampp\htdocs\send_form_email.php on line 10</p>
  
  <pre><code>&lt;?php $username = $_POST['username'];
  $email = $_POST['email'];
  $phonenumber = $_POST['phonenumber'];
  $location = $_POST['location'];
  $description = $_POST['description'];
  $formcontent="From: $username \n Message $description";
  $recipient = "ladipupo6@gmail.com";
  $subject = "Contact Form";
  $mailheader = "From: $email \r\n";
  mail('ladipupo6@gmail.com', $subject, $formcontent, $headers = "From: 
  ladipupo6@gmail.com");
  echo "Thank You!";
   ?&gt;
  </code></pre>
  
  <p>php.ini settings</p>
  
  <pre><code>[mail function]
  ; For Win32 only.
  ; http://php.net/smtp
  SMTP= smtp.mailtrap.io
  ; http://php.net/smtp-port
  smtp_port=25
  
  ; For Win32 only.
  ; http://php.net/sendmail-from
  
  sendmail_from = ladipupo6@gmail.com
  </code></pre>