Browse Source

Hopefully fixed the "unbalanced <" error

Tyler Akins 24 years ago
parent
commit
d92f40e1af
1 changed files with 5 additions and 0 deletions
  1. 5 0
      functions/smtp.php

+ 5 - 0
functions/smtp.php

@@ -515,6 +515,11 @@
       // replace them with \r\n.  
       $body = ereg_replace("\r\n", "\n", $body);
       $body = ereg_replace("\n", "\r\n", $body);
+      
+      // Make sure that $t, $c, and $b do not contain newlines.
+      $t = ereg_replace("[\n|\r]", "", $t);
+      $c = ereg_replace("[\n|\r]", "", $c);
+      $b = ereg_replace("[\n|\r]", "", $b);
 
       if ($useSendmail) {
          $length = sendSendmail($t, $c, $b, $subject, $body, $more_headers);