From: Marc G. K. <st...@us...> - 2005-02-18 00:39:58
|
Update of /cvsroot/squirrelmail/squirrelmail/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21532/src Modified Files: Tag: SM-1_4-STABLE printer_friendly_main.php read_body.php Log Message: Fixed bug #1124764. Show unsafe images in printable view when view_unsafe_images is set to true. Index: printer_friendly_main.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/src/printer_friendly_main.php,v retrieving revision 1.14.2.4 retrieving revision 1.14.2.5 diff -u -w -r1.14.2.4 -r1.14.2.5 --- printer_friendly_main.php 27 Dec 2004 15:04:00 -0000 1.14.2.4 +++ printer_friendly_main.php 18 Feb 2005 00:39:49 -0000 1.14.2.5 @@ -27,6 +27,7 @@ error_box(_("Invalid URL"),$color); } else { $passed_id= (int) $passed_id; + $view_unsafe_images = (bool) $_GET['view_unsafe_images']; /* end globals */ displayHtmlHeader( _("Printer Friendly"), '', false, true ); echo '<frameset rows="60, *">' . "\n"; @@ -35,6 +36,7 @@ echo '<frame src="printer_friendly_bottom.php?passed_ent_id=' . urlencode($passed_ent_id) . '&mailbox=' . urlencode($mailbox) . '&passed_id=' . $passed_id + . '&view_unsafe_images='.$view_unsafe_images . '" name="bottom_frame" frameborder="0" />' . "\n"; echo "</frameset>\n"; } Index: read_body.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/src/read_body.php,v retrieving revision 1.283.2.21 retrieving revision 1.283.2.22 diff -u -w -r1.283.2.21 -r1.283.2.22 --- read_body.php 28 Dec 2004 13:46:23 -0000 1.283.2.21 +++ read_body.php 18 Feb 2005 00:39:49 -0000 1.283.2.22 @@ -117,9 +117,17 @@ function printer_friendly_link($mailbox, $passed_id, $passed_ent_id, $color) { global $javascript_on; + /* hackydiehack */ + if( !sqgetGlobalVar('view_unsafe_images', $view_unsafe_images, SQ_GET) ) { + $view_unsafe_images = false; + } else { + $view_unsafe_images = true; + } + $params = '?passed_ent_id=' . urlencode($passed_ent_id) . '&mailbox=' . urlencode($mailbox) . - '&passed_id=' . urlencode($passed_id); + '&passed_id=' . urlencode($passed_id). + '&view_unsafe_images='. (bool) $view_unsafe_images; $print_text = _("View Printable Version"); |