added DELETE for when viewing a message
[squirrelmail.git] / src / read_body.php
index b660fef..84f7855 100644 (file)
@@ -13,6 +13,7 @@
    displayPageHeader($mailbox);
    $body = fetchBody($imapConnection, $passed_id);
    getMessageHeaders($imapConnection, $passed_id, $passed_id, $f, $s, $d);
+//   setMessageFlag($imapConnection, $passed_id, $passed_id, "Seen");
 
    $subject = $s[0];
    $d[0] = ereg_replace("  ", " ", $d[0]);
 //   $date = getDateString($date);
    $date = $d[0];
    $from_name = getSenderName($f[0]);
+   $urlMailbox = urlencode($mailbox);
 
-   echo "<TABLE COLS=1 WIDTH=95% BORDER=0 ALIGN=CENTER>\n";
-   echo "   <TR><TD BGCOLOR=DCDCDC>&nbsp;</TD></TR>";
-   echo "   <TR><TD BGCOLOR=FFFFFF>";
+   echo "<BR>";
+   echo "<TABLE COLS=1 WIDTH=95% BORDER=0 ALIGN=CENTER CELLPADDING=2>\n";
+   echo "   <TR><TD BGCOLOR=DCDCDC WIDTH=100%>";
+   echo "      <FONT FACE=\"Arial,Helvetica\" SIZE=2>";
+   echo "      <A HREF=\"right_main.php?sort=$sort&startMessage=$startMessage&mailbox=$urlMailbox\">Message List</A>&nbsp;&nbsp;";
+   echo "      <A HREF=\"delete_message.php?mailbox=$urlMailbox&message=$passed_id&sort=$sort&startMessage=1\">Delete</A>&nbsp;&nbsp;";
+   echo "      </FONT>";
+   echo "   </TD></TR>";
+   echo "   <TR><TD BGCOLOR=FFFFFF WIDTH=100%>";
    echo "   <TABLE COLS=2 WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=2>\n";
    echo "      <TR>\n";
    /** subject **/
@@ -52,7 +60,7 @@
 
    echo "   </TABLE></TD></TR>\n";
 
-   echo "   <TR><TD BGCOLOR=FFFFFF><BR>\n";
+   echo "   <TR><TD BGCOLOR=FFFFFF WIDTH=100%><BR>\n";
    $i = 0;
    while ($i < count($body)) {
       echo "$body[$i]";