SF.net SVN: postfixadmin: [396] trunk/sendmail.php
Brought to you by:
christian_boltz,
gingerdog
From: <chr...@us...> - 2008-06-29 16:11:31
|
Revision: 396 http://postfixadmin.svn.sourceforge.net/postfixadmin/?rev=396&view=rev Author: christian_boltz Date: 2008-06-29 09:11:37 -0700 (Sun, 29 Jun 2008) Log Message: ----------- sendmail.php: - do not escape_string() the mailbody - having \n in mails instead of real newlines is not nice. This fixes https://sourceforge.net/tracker/?func=detail&atid=937964&aid=2005839&group_id=191583 Thanks to Tabmow for the report! - added missing newline between headers and message body Modified Paths: -------------- trunk/sendmail.php Modified: trunk/sendmail.php =================================================================== --- trunk/sendmail.php 2008-06-26 20:26:22 UTC (rev 395) +++ trunk/sendmail.php 2008-06-29 16:11:37 UTC (rev 396) @@ -49,15 +49,20 @@ $fHeaders .= "MIME-Version: 1.0\n"; $fHeaders .= "Content-Type: text/plain; charset=utf-8\n"; $fHeaders .= "Content-Transfer-Encoding: 8bit\n"; + $fHeaders .= "\n"; - $fHeaders .= escape_string ($_POST['fBody']); + $tBody = $_POST['fBody']; + if (get_magic_quotes_gpc ()) + { + $tBody = stripslashes($tBody); + } + $fHeaders .= $tBody; if (empty ($fTo) or !check_email ($fTo)) { $error = 1; $tTo = escape_string ($_POST['fTo']); $tSubject = escape_string ($_POST['fSubject']); - $tBody = escape_string ($_POST['fBody']); $tMessage = $PALANG['pSendmail_to_text_error']; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |