* Fixed weird addressbook problem over SMTP
authorfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 7 Mar 2001 18:03:44 +0000 (18:03 +0000)
committerfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 7 Mar 2001 18:03:44 +0000 (18:03 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1171 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/smtp.php

index 36b7751..9d7bce9 100644 (file)
             $ret .= '<'.$result['email'].'>';
             $array[$i] = $ret;
          }
+        else
+        {
+           $array[$i] = '<' . $array[$i] . '>';
+        }
       }
       return $array;
    }
          $header .= "Date: $date\r\n";
          $header .= "Subject: $subject\r\n";
          $header .= "From: $from\r\n";
-         $header .= "To: $to_list \r\n";    // Who it's TO
+         $header .= "To: $to_list\r\n";    // Who it's TO
 
         /* Insert headers from the $more_headers array */
         if(is_array($more_headers)) {
 
       /** send who the recipients are */
       for ($i = 0; $i < count($to); $i++) {
-         fputs($smtpConnection, "RCPT TO:<$to[$i]>\r\n");
+         fputs($smtpConnection, "RCPT TO: $to[$i]\r\n");
          $tmp = fgets($smtpConnection, 1024);
          errorCheck($tmp, $smtpConnection);
       }