6 * This file shows an attached image
8 * @copyright © 1999-2007 The SquirrelMail Project Team
9 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
11 * @package squirrelmail
14 /** This is the image page */
15 define('PAGE_NAME', 'image');
18 * Include the SquirrelMail initialization file.
20 require('../include/init.php');
22 displayPageHeader($color);
25 if ( sqgetGlobalVar('passed_id', $temp, SQ_GET
) ) {
26 $passed_id = (int) $temp;
28 sqgetGlobalVar('mailbox', $mailbox, SQ_GET
);
29 sqgetGlobalVar('ent_id', $ent_id, SQ_GET
);
30 sqgetGlobalVar('QUERY_STRING', $QUERY_STRING, SQ_SERVER
);
34 '<table width="100%" border="0" cellspacing="0" cellpadding="2" align="center">' .
36 '<tr><td bgcolor="' . $color[0] . '">' .
37 '<div style="text-align: center;"><b>' .
38 _("Viewing an image attachment") . " - ";
40 $msg_url = 'read_body.php?' . $QUERY_STRING;
41 $msg_url = set_url_var($msg_url, 'ent_id', 0);
42 echo '<a href="'.$msg_url.'">'. _("View message") . '</a>';
45 $DownloadLink = '../src/download.php?passed_id=' . $passed_id .
46 '&mailbox=' . urlencode($mailbox) .
47 '&ent_id=' . urlencode($ent_id) . '&absolute_dl=true';
51 <tr
><td align
="center">
52 <a href
="<?php echo $DownloadLink; ?>"><?php
echo _("Download this as a file"); ?
></a
>
53 <br
/> 
;</td
></tr
></table
>
55 <table border
="0" cellspacing
="0" cellpadding
="2" align
="center">
56 <tr
><td bgcolor
="<?php echo $color[4]; ?>">
57 <img src
="<?php echo $DownloadLink; ?>" />
61 $oTemplate->display('footer.tpl');