version 1.81, 2004/05/05 23:04:57
|
version 1.83, 2004/05/11 10:42:41
|
Line 84 sub list_discussion {
|
Line 84 sub list_discussion {
|
$prevread = $dischash{$lastkey}; |
$prevread = $dischash{$lastkey}; |
} |
} |
|
|
|
# Get discussion display default setting for user |
|
my %userenv = &Apache::lonnet::get('environment',['discdisplay'],$ENV{'user.domain'},$ENV{'user.name'}); |
|
my $discdisplay=$userenv{'discdisplay'}; |
|
if ($discdisplay eq 'unread') { |
|
$showonlyunread = 1; |
|
} |
|
|
|
# Override user's default if user specified display setting for this discussion |
if (defined($dischash{$showkey})) { |
if (defined($dischash{$showkey})) { |
$showonlyunread = $dischash{$showkey}; |
$showonlyunread = $dischash{$showkey}; |
} |
} |
Line 159 sub list_discussion {
|
Line 167 sub list_discussion {
|
$subject=&Apache::lontexconvert::msgtexconverted($subject); |
$subject=&Apache::lontexconvert::msgtexconverted($subject); |
} |
} |
if ($contrib{$idx.':attachmenturl'}) { |
if ($contrib{$idx.':attachmenturl'}) { |
my ($fname,$ft) |
my ($fname) |
=($contrib{$idx.':attachmenturl'}=~/\/(\w+)\.(\w+)$/); |
=($contrib{$idx.':attachmenturl'}=~m|/([^/]+)$|); |
$message.='<p>'.&mt('Attachment').': <a href="'. |
&Apache::lonnet::allowuploaded('/adm/feedback', |
&Apache::lonnet::tokenwrapper( |
$contrib{$idx.':attachmenturl'}); |
$contrib{$idx.':attachmenturl'}). |
$message.='<p>'.&mt('Attachment'). |
'"><tt>'.$fname.'.'.$ft.'</tt></a></p>'; |
': <a href="'.$contrib{$idx.':attachmenturl'}.'"><tt>'. |
|
$fname.'</tt></a></p>'; |
} |
} |
if ($message) { |
if ($message) { |
if ($hidden) { |
if ($hidden) { |
Line 976 sub handler {
|
Line 985 sub handler {
|
my $attachmenturl=''; |
my $attachmenturl=''; |
if ($ENV{'form.attachment.filename'}) { |
if ($ENV{'form.attachment.filename'}) { |
unless (length($ENV{'form.attachment'})>131072) { |
unless (length($ENV{'form.attachment'})>131072) { |
$attachmenturl=&Apache::lonnet::userfileupload('attachment'); |
$attachmenturl=&Apache::lonnet::userfileupload('attachment',undef,'feedback'); |
} |
} |
} |
} |
# Filter HTML out of message (could be nasty) |
# Filter HTML out of message (could be nasty) |