From 968601f1f5e7366ddc8aa72d00d2f727d9eab572 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Thu, 30 Oct 2014 09:22:05 +0100 Subject: Give higher priority to the 'subject' parameter from request or plugin --- program/steps/mail/compose.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'program/steps') diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc index e5c2fb108..751729cc5 100644 --- a/program/steps/mail/compose.inc +++ b/program/steps/mail/compose.inc @@ -1452,6 +1452,9 @@ function rcmail_compose_subject($attrib) if (isset($_POST['_subject'])) { $subject = rcube_utils::get_input_value('_subject', rcube_utils::INPUT_POST, TRUE); } + else if (!empty($COMPOSE['param']['subject'])) { + $subject = $COMPOSE['param']['subject']; + } // create a reply-subject else if ($compose_mode == RCUBE_COMPOSE_REPLY) { if (preg_match('/^re:/i', $MESSAGE->subject)) @@ -1473,9 +1476,6 @@ function rcmail_compose_subject($attrib) else if ($compose_mode == RCUBE_COMPOSE_DRAFT || $compose_mode == RCUBE_COMPOSE_EDIT) { $subject = $MESSAGE->subject; } - else if (!empty($COMPOSE['param']['subject'])) { - $subject = $COMPOSE['param']['subject']; - } $out = $form_start ? "$form_start\n" : ''; $out .= $textfield->show($subject); -- cgit v1.2.3