X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=src%2Fprinter_friendly_bottom.php;h=9b5e6c0daedfaf2cd33b89aba3bbcbc6fe53b84f;hb=ddbd13dbf48d3428623e07f611d0156b5fe3c1f2;hp=e0f338a971046eb45473fe75ecac53b3d317289f;hpb=be7a2943b374d951bf8d3f9b17220dde9eaa3295;p=squirrelmail.git diff --git a/src/printer_friendly_bottom.php b/src/printer_friendly_bottom.php index e0f338a9..9b5e6c0d 100644 --- a/src/printer_friendly_bottom.php +++ b/src/printer_friendly_bottom.php @@ -8,12 +8,15 @@ * * - this is the page that does all the work, really. * - * @copyright © 1999-2006 The SquirrelMail Project Team + * @copyright © 1999-2007 The SquirrelMail Project Team * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @version $Id$ * @package squirrelmail */ +/** This is the printer_friendly_bottom page */ +define('PAGE_NAME', 'printer_friendly_bottom'); + /** * Include the SquirrelMail initialization file. */ @@ -29,6 +32,7 @@ require_once(SM_PATH . 'functions/url_parser.php'); /* get some of these globals */ sqgetGlobalVar('passed_id', $passed_id, SQ_GET); sqgetGlobalVar('mailbox', $mailbox, SQ_GET); +sqgetGlobalVar('messages', $messages, SQ_SESSION); if (! sqgetGlobalVar('passed_ent_id', $passed_ent_id, SQ_GET) ) { $passed_ent_id = ''; @@ -52,7 +56,7 @@ if ($passed_ent_id) { $rfc822_header = $message->rfc822_header; /* From and Date are usually fine as they are... */ $from = $rfc822_header->getAddr_s('from'); -$date = getLongDateString($rfc822_header->date); +$date = getLongDateString($rfc822_header->date, $rfc822_header->date_unparsed); $subject = trim($rfc822_header->subject); /* we can clean these up if the list is too long... */ @@ -72,8 +76,8 @@ if ($ent_ar[0] != '') { $body .= '
'; } } - $hookResults = do_hook('message_body', $body); - $body = $hookResults[1]; + /* Note that $body is passed to this hook (and modified) by reference as of 1.5.2 */ + do_hook('message_body', $body); } else { $body = _("Message not printable"); }