Update of /cvsroot/squirrelmail/squirrelmail/src
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv29583/src
Modified Files:
view_text.php
Log Message:
Provide View Unsafe Images link on viewing a text/html attachment.
Thanks `Bicster'
Index: view_text.php
===================================================================
RCS file: /cvsroot/squirrelmail/squirrelmail/src/view_text.php,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -w -r1.40 -r1.41
--- view_text.php 5 Aug 2006 14:39:17 -0000 1.40
+++ view_text.php 21 Aug 2006 19:34:27 -0000 1.41
@@ -48,6 +48,9 @@
$msg_url = 'read_body.php?' . $QUERY_STRING;
$msg_url = set_url_var($msg_url, 'ent_id', 0);
$dwnld_url = '../src/download.php?' . $QUERY_STRING . '&absolute_dl=true';
+$unsafe_url = 'view_text.php?' . $QUERY_STRING;
+$unsafe_url = set_url_var($unsafe_url, 'view_unsafe_images', 1);
+
$body = mime_fetch_body($imapConnection, $passed_id, $ent_id);
$body = decodeBody($body, $encoding);
@@ -62,10 +65,12 @@
}
if ($type1 == 'html' || (isset($override_type1) && $override_type1 ==
'html')) {
+ $ishtml = TRUE;
$body = MagicHTML( $body, $passed_id, $message, $mailbox);
// html attachment with character set information
- if (! empty($charset))
+ if (! empty($charset)) {
$body = charset_decode($charset,$body,false,true);
+ }
} else {
translateText($body, $wrap_at, $charset);
}
@@ -80,6 +85,9 @@
?>
</b></td><tr><tr><td><div style="text-align: center;">
<?php
+if ( $ishtml ) {
+ echo '<a href="' . $unsafe_url . '">' . _("View Unsafe Images") . '</a> |
';
+}
echo '<a href="' . $dwnld_url . '">' . _("Download this as a file") . '</a>';
?>
</div><br />
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
|