Printable version should not use theme colors but fixed black-text-on-white-background.
[squirrelmail.git] / src / printer_friendly_bottom.php
index c334b0d2f4b6279cece562a7026c39b4c66a849c..3fa0c95b82e2d081c857fd587cb5e8475eca25ba 100644 (file)
@@ -27,18 +27,16 @@ require_once(SM_PATH . 'functions/page_header.php');
 require_once(SM_PATH . 'functions/html.php');
 
 /* get some of these globals */
-$key = $_COOKIE['key'];
-$username = $_SESSION['username'];
-$onetimepad = $_SESSION['onetimepad'];
+sqgetGlobalVar('username', $username, SQ_SESSION);
+sqgetGlobalVar('key', $key, SQ_COOKIE);
+sqgetGlobalVar('onetimepad', $onetimepad, SQ_SESSION);
 
-$passed_id = (int) $_GET['passed_id'];
-$mailbox = $_GET['mailbox'];
+sqgetGlobalVar('passed_id', $passed_id, SQ_GET);
+sqgetGlobalVar('mailbox', $mailbox, SQ_GET);
 
-if (!isset($_GET['passed_ent_id'])) {
+if (! sqgetGlobalVar('passed_ent_id', $passed_ent_id, SQ_GET) ) {
     $passed_ent_id = '';
-} else {
-    $passed_ent_id = $_GET['passed_ent_id'];
-}
+} 
 /* end globals */
 
 $pf_cleandisplay = getPref($data_dir, $username, 'pf_cleandisplay');
@@ -115,7 +113,7 @@ $subject = decodeHeader($subject);
 /* --start browser output-- */
 displayHtmlHeader( _("Printer Friendly"), '', FALSE );
 
-echo "<body text=\"$color[8]\" bgcolor=\"$color[4]\" link=\"$color[7]\" vlink=\"$color[7]\" alink=\"$color[7]\">\n" .
+echo '<body text="#000000" bgcolor="#FFFFFF" link="#000000" vlink="#000000" alink="#000000">'."\n" .
      /* headers (we use table because translations are not all the same width) */
      html_tag( 'table', '', 'center', '', 'cellspacing="0" cellpadding="0" border="0" width="100%"' ) .
      html_tag( 'tr',