Added subscription stuff so you only view folders that you're subscribed to.
[squirrelmail.git] / functions / smtp.php
index a15f4af5ee53d5f47b4cc1458143c6c46ce537a8..f75ea3e808009f4924dbab4a817a27437376712c 100644 (file)
@@ -76,6 +76,7 @@
       $tmp = nl2br(htmlspecialchars(fgets($smtpConnection, 1024)));
       errorCheck($tmp);
 
+      $subject = stripslashes($subject);
       fputs($smtpConnection, "Subject: $subject\n"); // Subject
       fputs($smtpConnection, "From: $from\n"); // Subject
       fputs($smtpConnection, "To: $to_list\n");    // Who it's TO
       if ($reply_to != "")
          fputs($smtpConnection, "Reply-To: $reply_to\n");
 
-
-      $body_ary = explode("\n", trim($body));
-      $body = "";
-      for ($i = 0; $i < count($body_ary); $i++) {
-         if ($body_ary[$i] == ".")
-            $body_ary[$i] = ".";
-         $body .= $body_ary[$i] . "\n";
-      }
+      $body = stripslashes($body);
       fputs($smtpConnection, "$body\n"); // send the body of the message
 
       fputs($smtpConnection, ".\n"); // end the DATA part