Fixes for creating of new tasks (double escape breakes string) and mail debug code
[mailer.git] / inc / functions.php
index 8928e602fa428c51ab064641ff281a61e17d5e90..cc3c83d5f3754330c93f29192e9119d0c8031515 100644 (file)
@@ -586,10 +586,10 @@ function sendEmail ($toEmail, $subject, $message, $isHtml = 'N', $mailHeader = '
        if (isDebugModeEnabled()) {
                // In debug mode we want to display the mail instead of sending it away so we can debug this part
                outputHtml('<pre>
-Headers : ' . str_replace('<', '&lt', str_replace('>', '&gt;', secureString(trim($mailHeader)))) . '
-To      : ' . $toEmail . '
-Subject : ' . $subject . '
-Message : ' . $message . '
+Headers : ' . htmlentities(trim($mailHeader)) . '
+To      : ' . htmlentities($toEmail) . '
+Subject : ' . htmlentities($subject) . '
+Message : ' . htmlentities($message) . '
 </pre>');
        } elseif (($isHtml == 'Y') && (isExtensionActive('html_mail'))) {
                // Send mail as HTML away