From: fidian Date: Thu, 1 Feb 2001 00:01:52 +0000 (+0000) Subject: Another workaround for an extra newline inside a form. X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=79be8a0b8f04dfadf8bde87fa38b37f60849bdd9;p=squirrelmail.git Another workaround for an extra newline inside a form. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1021 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/src/compose.php b/src/compose.php index 33e7d0fc..12b72be2 100644 --- a/src/compose.php +++ b/src/compose.php @@ -40,6 +40,9 @@ include("../src/load_prefs.php"); + if (!isset($attachments)) + $attachments = array(); + // This function is used when not sending or adding attachments function newMail () { global $forward_id, $imapConnection, $msg, $ent_num, $body_ary, $body, @@ -299,8 +302,6 @@ echo " \n"; echo "
"._("Attach:"); echo " \n"; - // echo " \n"; echo " \n"; echo "   \n"; @@ -399,6 +400,7 @@ $HTTP_POST_FILES['attachfile']['tmp_name'] != 'none') $AttachFailure = saveAttachedFiles(); if (checkInput(false) && ! isset($AttachFailure)) { + $mailbox = ereg_replace("([\n|\r])", '', $mailbox); $urlMailbox = urlencode ($mailbox); if (! isset($reply_id)) $reply_id = 0; @@ -480,5 +482,3 @@ sqimap_logout($imapConnection); } ?> - -