2
# $Id: queryexpunge.tcl 391 2007-01-25 03:53:59Z mikes@u.washington.edu $
3
# ========================================================================
4
# Copyright 2006 University of Washington
6
# Licensed under the Apache License, Version 2.0 (the "License");
7
# you may not use this file except in compliance with the License.
8
# You may obtain a copy of the License at
10
# http://www.apache.org/licenses/LICENSE-2.0
12
# ========================================================================
16
# Purpose: CGI script to generate html form used to confirm
17
# deleted message expunge
19
# Input (Assumed set by sourcing script):
20
# fn : Name of folder getting expunged
21
# delcount : Number of deleted messages
25
# HTML/CSS data representing the message specified
26
# by the 'uid' argument
28
# inherit global config
39
WPStdHtmlHdr "Confirm Expunge"
43
cgi_body BGCOLOR="$_wp(bordercolor)" {
45
catch {WPCmd PEInfo set help_context expunge}
47
cgi_table border=0 cellspacing=0 cellpadding=2 width="100%" height="100%" {
49
cgi_table_data valign=top align=center class=dialog {
50
cgi_form $_wp(appdir)/fr_index method=get name=confirm target=spec {
51
cgi_text "cid=[WPCmd PEInfo key]" type=hidden notab
53
set mbn [WPCmd PEMailbox mailboxname]
54
cgi_table border=0 cellspacing=8 cellpadding=8 width="75%" {
56
if {[catch {WPCmd PEMailbox flagcount deleted} delcount] == 0 && $delcount > 0
57
&& [catch {WPCmd PEMailbox messagecount} messcount] == 0} {
60
cgi_table_data align=center valign=middle height=50 {
61
cgi_table bgcolor=yellow background=[WPimg dstripe] cellpadding=6 {
64
cgi_table bgcolor=black cellpadding=6 {
67
cgi_puts [cgi_font size=+2 color=yellow [cgi_bold "CAUTION!"]]
77
if {$delcount == $messcount} {
80
set m1 "The [cgi_bold only] message in the folder [cgi_bold $mbn] is deleted."
81
set m2 "that [cgi_bold single] message"
84
set m1 "[cgi_bold Both] messages in the folder [cgi_bold $mbn] are deleted."
85
set m2 "[cgi_bold "both"] messages"
88
set m1 "[cgi_span "style=font-weight: bold; color: red" "All $messcount messages"] in the folder [cgi_bold $mbn] are marked for deletion. This includes any messages that might <u>not</u> be <u>visible</u> on the screen."
89
set m2 "[cgi_bold [cgi_span "style=font-size: bigger; color: red; text-decoration: underline" "all messages"]]"
93
append m1 "[cgi_nl][cgi_nl]Expunge now will leave this folder "
94
append m1 "[cgi_span "style=font-weight: bold; color: red" empty]. "
95
#append m1 "[cgi_nl][cgi_nl]Please acknowledge below that you understand there will be [cgi_span "style=font-weight: bold; color: red" "no more messages"] within this folder when the expunge is complete."
96
append m1 "[cgi_nl][cgi_nl][cgi_buffer {cgi_checkbox "emptyit=1"}] "
97
append m1 "I acknowledge expunge will leave folder [cgi_bold $mbn] [cgi_span "style=font-weight: bold; color: red" empty]."
98
set style "style=\"border: 1px solid #663333; background-color: #ffcc66;\""
109
set m1 "Your folder [cgi_bold $mbn] contains $messcount messages, of which [cgi_bold $delcount] $whch deleted."
110
set m2 "[cgi_span "style=font-size: bigger; font-weight: bold" $delcount] message${plrl}"
116
cgi_table_data align=center $style {
122
cgi_table_data align=center {
123
cgi_puts "Do you wish to [cgi_span "style=color: red ; font-weight: bold" "permanently remove"] $m2 now?"
128
cgi_table_data align=center {
129
cgi_submit_button "expunge=Yes, Remove $m3 message[WPplural $delcount]" tabindex=2
134
cgi_table_data align=center {
135
cgi_submit_button "cancel=No, Return to '$mbn'" tabindex=1 checked selected default
140
cgi_table_data align=center {
141
cgi_puts "There are [cgi_bold no] messages currently marked for deletion in the folder [cgi_bold [WPCmd PEMailbox mailboxname]]."
145
if {[WPCmd PEInfo feature enable-aggregate-command-set]} {
146
switch [WPCmd PEInfo aggtabstate] {
148
lappend methods "Click the [cgi_img [WPimg slideout] style=vertical-align:middle] tab to expose aggregate operations"
149
lappend methods "Place a mark in the checkbox next to each desired message"
150
lappend methods "Click the [cgi_italic Delete] button"
153
lappend methods "Place a mark in the checkbox next to each desired message"
154
lappend methods "Click the [cgi_italic Delete] button"
157
lappend methods "Place a mark in the checkbox next to each desired message"
158
lappend methods "Within the Message Status box, choose [cgi_bold Deleted] from the drop-down list of flag choices"
159
lappend methods "Click the [cgi_italic Set] button"
164
cgi_table_data align=center {
165
cgi_puts "To mark a message for deletion while viewing it, simply click the [cgi_italic Delete] button at the top of the Message View page."
170
cgi_table_data align=center {
171
cgi_puts "To mark messages for deletion in the Message List:"
181
cgi_table_data align=center {
182
cgi_puts "To mark a message for deletion, click the [cgi_italic Delete] button while viewing the message."
188
cgi_table_data align=center {
189
cgi_puts "Click [cgi_italic OK] to return to the Message List."
192
cgi_submit_button cancel=OK