';
# Functionlist
@@ -2471,10 +2201,18 @@ sub displaymessage {
}
$functions .= &Apache::lonhtmlcommon::end_funclist();
+ # Navigationlist
+ $functions.=&Apache::lonhtmlcommon::start_funclist(
+ &mt('Navigation'));
+ foreach my $item (@navigationlist) {
+ $functions.=&Apache::lonhtmlcommon::add_item_funclist($item);
+ }
+ $functions .= &Apache::lonhtmlcommon::end_funclist();
+
# Actionlist
if (@actionlist) {
- my $legendtext=&mt('Currently available actions (will open extra window)');
- $functions.=&Apache::lonhtmlcommon::start_funclist($legendtext);
+ $functions.=&Apache::lonhtmlcommon::start_funclist(
+ &mt('Currently available actions (will open extra window)'));
foreach my $item (@actionlist) {
$functions.=&Apache::lonhtmlcommon::add_item_funclist($item);
}
@@ -2638,12 +2376,14 @@ sub displaymessage {
}
if ($content{'group'} ne '') {
if (&check_group_priv($content{'group'})) {
- $groupcclist = join(', ',@{$recipients{'group_cc_broadcast'}});
- if ($groupcclist) {
- $r->print(&Apache::lonhtmlcommon::row_title(&mt('Group Cc'))
- .$groupcclist
- .&Apache::lonhtmlcommon::row_closure()
- );
+ if (ref($recipients{'group_cc_broadcast'}) eq 'ARRAY') {
+ $groupcclist = join(', ',@{$recipients{'group_cc_broadcast'}});
+ if ($groupcclist) {
+ $r->print(&Apache::lonhtmlcommon::row_title(&mt('Group Cc'))
+ .$groupcclist
+ .&Apache::lonhtmlcommon::row_closure()
+ );
+ }
}
}
}
@@ -2651,14 +2391,22 @@ sub displaymessage {
}
# Course
- if ($content{'courseid'}) {
- $r->print(&Apache::lonhtmlcommon::row_title(&mt($crstype))
- .$courseinfo{'description'}
- );
- if ($content{'coursesec'}) {
- $r->print(' ('.&mt('Section').': '.$content{'coursesec'}.')');
+ if ($content{'courseid'} ne '') {
+ if ($content{'courseid'} =~ m{^$match_domain\_$match_courseid$}) {
+ my %courseinfo;
+ %courseinfo=&Apache::lonnet::coursedescription($content{'courseid'},
+ {'one_time' => 1});
+ my $description = $courseinfo{'description'};
+ if ($description ne '') {
+ $r->print(&Apache::lonhtmlcommon::row_title(&mt($crstype))
+ .$description
+ );
+ if ($content{'coursesec'}) {
+ $r->print(' ('.&mt('Section').': '.$content{'coursesec'}.')');
+ }
+ $r->print(&Apache::lonhtmlcommon::row_closure());
+ }
}
- $r->print(&Apache::lonhtmlcommon::row_closure());
}
$r->print(&Apache::lonhtmlcommon::row_title(&mt('Time'))
.$content{'time'}
@@ -3167,7 +2915,7 @@ sub sendoffmail {
my ($recuname,$recdomain)=split(/\:/,$address);
my $msgtxt = $savemsg;
if ($toaddr{$address}) {
- $msgtxt.='
'.$toaddr{$address};
+ $msgtxt.="\n".'
'."\n".$toaddr{$address};
}
my @thismsg;
if ($msgtype eq 'critical') {
@@ -3292,6 +3040,9 @@ sub sendoffmail {
$r->print($message);
}
}
+ } else {
+ &printheader($r,'','Messages cancelled.');
+ return 'cancelled';
}
return $sendstatus;
}
@@ -3312,15 +3063,13 @@ sub handler {
&Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},
['display','replyto','forward','markread','markdel','markunread',
'sendreply','compose','sendmail','critical','recname','recdom',
- 'recordftf','sortedby','block','folder','startdis','interdis',
+ 'recordftf','sortedby','folder','startdis','interdis',
'showcommentbaseurl','dismode','group','subject','text','ref',
'msgstatus']);
$sqs='&sortedby='.$env{'form.sortedby'};
# ------------------------------------------------------ They checked for email
- unless ($env{'form.block'}) {
- &Apache::lonnet::put('email_status',{'recnewemail'=>0});
- }
+ &Apache::lonnet::put('email_status',{'recnewemail'=>0});
# ----------------------------------------------------------------- Breadcrumbs
@@ -3409,7 +3158,7 @@ sub handler {
&statuschange($env{'form.markdel'},'deleted',$folder);
if (!$result) {
my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete the message.'),1);
- $message .= '
'.$msg.'
';
+ $message .= '
'.$msg.'
';
$message = &Apache::loncommon::confirmwrapper($message);
$r->print($message);
}
@@ -3459,7 +3208,7 @@ sub handler {
&printheader($r,'','Moved Messages');
if (!defined($gotfolders{$destfolder})) {
$r->print(&mt('Destination folder [_1] is not a valid folder',
- $destfolder));
+ '
'.$destfolder.''));
} else {
my ($total,$failed,@failed_msg)=(0,0);
my @to_move = &Apache::loncommon::get_env_multiple('form.delmark');
@@ -3476,8 +3225,8 @@ sub handler {
my $message = '';
if ($failed) {
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Failed to move [quant,_1,message]',$failed),1);
- $message .= '
'.
- join("
\n
",@failed_msg).
+ $message .= '
'.
+ join("
\n
",@failed_msg).
"
\n";
}
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Moved [quant,_1,message]',$total));
@@ -3504,8 +3253,8 @@ sub handler {
my $message = '';
if ($failed) {
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete [quant,_1,message]',$failed),1);
- $message .= '
'.
- join("
\n
",@failed_msg).
+ $message .= '
'.
+ join("
\n
",@failed_msg).
"
\n";
}
$message .= &Apache::lonhtmlcommon::confirm_success(&mt('Deleted [quant,_1,message]',$total));
@@ -3523,8 +3272,6 @@ sub handler {
&compout($r,'','',$env{'form.compose'});
} elsif ($env{'form.recordftf'}) {
&facetoface($r,$env{'form.recordftf'});
- } elsif ($env{'form.block'}) {
- &examblock($r,$env{'form.block'});
} elsif ($env{'form.sendmail'}) {
if ($env{'form.multiforward'}) {
&printheader($r,'','Messages being sent.');