浏览代码

Hopefully fixed the "unbalanced <" error

Tyler Akins 24 年之前
父节点
当前提交
d92f40e1af
共有 1 个文件被更改,包括 5 次插入0 次删除
  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);