title: Email Sending from Local Server in PHP
body: <p>I have my file mail.php :</p>
  
  <pre><code>&lt;html&gt;
  &lt;body&gt;
  
  &lt;?php
  if (isset($_REQUEST['email']))
  //if "email" is filled out, send email
    {
    //send email
    $email = $_REQUEST['email'] ;
    $subject = $_REQUEST['subject'] ;
    $message = $_REQUEST['message'] ;
    mail("syedsamiruddin29@gmail.com", $subject,
    $message, "From:" . $email);
    echo "Thank you for using our mail form";
    }
  else
  //if "email" is not filled out, display the form
    {
    echo "&lt;form method='post' action='mail.php'&gt;
    Email: &lt;input name='email' type='text' /&gt;&lt;br /&gt;
    Subject: &lt;input name='subject' type='text' /&gt;&lt;br /&gt;
    Message:&lt;br /&gt;
    &lt;textarea name='message' rows='15' cols='40'&gt;
    &lt;/textarea&gt;&lt;br /&gt;
    &lt;input type='submit' /&gt;
    &lt;/form&gt;";
    }
  ?&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>but when i run it. i get this error :</p>
  
  <pre><code>Warning: mail() [function.mail]: Failed to connect to mailserver at "127.0.0.1" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Program Files\EasyPHP-5.3.8.1\www\safepay247\mail.php on line 13
  Thank you for using our mail form
  </code></pre>
  
  <p>what im trying to do is to send an email to my email id : syedsamiruddin29@gmail.com using php to the person's email written in the input type.</p>
  
  <p>Ive gone through many videos but none help me solve the php.ini problem.</p>