title: PHP Mailer Error: Mailer Error - must provide at least one recipient email address
body: <p>I'm having and an issue with php mailer script. Using mamp the script works, but on the server I get an error (I've omitted sensitive info).</p>
  
  <blockquote>
    <p>"Invalid address: [valid email] Mailer Error: You must
    provide at least one recipient email address."</p>
  </blockquote>
  
  <p>Heres my code:</p>
  
  <pre><code>require_once("includes/phpmailer/class.phpmailer.php");
  
      $mail = new PHPMailer();
      $mail-&gt;IsSMTP();
  
      $mail-&gt;SMTPAuth   = true;                  
      $mail-&gt;Host       = "smtp.emailsrvr.com"; 
      $mail-&gt;SMTPDebug  = 2;                    
      $mail-&gt;Port       = 25;                    
      $mail-&gt;Username   = "test@test.com"; 
      $mail-&gt;Password   = "test";
  
      $mail-&gt;Subject = "Subject";
  
      $mail-&gt;SetFrom($_POST['email'], $_POST['name']);
      $mail-&gt;AddReplyTo($_POST['email'], $_POST['name']);
  
      $address = "test@test.com";
      $mail-&gt;AddAddress($address, "name");
  
      $body = "&lt;p&gt;test&lt;/p&gt;";
  
      $mail-&gt;MsgHTML($body);
  
  
      if(!$mail-&gt;Send()) {
        echo "Mailer Error: " . $mail-&gt;ErrorInfo;
      } else {
        echo "Message sent!";
      }
  </code></pre>
  
  <p>If it helps, I am using the rackspace email apps. </p>
  
  <p>Im not very savy with php or server setups unfortunately so if anyone can help that would be great!</p>