--- loncom/interface/lonmsgdisplay.pm 2010/11/20 13:19:49 1.124.4.12 +++ loncom/interface/lonmsgdisplay.pm 2009/07/25 23:16:04 1.128 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Routines for messaging display # -# $Id: lonmsgdisplay.pm,v 1.124.4.12 2010/11/20 13:19:49 raeburn Exp $ +# $Id: lonmsgdisplay.pm,v 1.128 2009/07/25 23:16:04 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -146,7 +146,7 @@ sub folderlist { ); $actions{'select_form_order'} = ['view','rename','delete']; - my %statushash = &Apache::lonlocal::texthash(&get_msgstatus_types()); + my %statushash = &get_msgstatus_types(); $statushash{'select_form_order'} = ['','new','read','replied','forwarded']; @@ -219,7 +219,8 @@ function folder_choice(targetform,caller |; my %show = ('select_form_order' => [10,20,50,100,200], map {$_=>$_} (10,20,50,100,200)); - + + $output .= '
@@ -272,13 +273,12 @@ sub get_permanent_folders { } sub get_msgstatus_types { - # Don't translate here! - my %statushash = ( - '' => 'Any', - 'new' => 'Unread', - 'read' => 'Read', - 'replied' => 'Replied to', - 'forwarded' => 'Forwarded', + my %statushash = &Apache::lonlocal::texthash( + '' => 'Any', + new => 'Unread', + read => 'Read', + replied => 'Replied to', + forwarded => 'Forwarded', ); return %statushash; } @@ -291,7 +291,7 @@ sub scrollbuttons { my %statushash = &get_msgstatus_types(); my $status; if ($msgstatus eq '') { - $status = 'All'; # Don't translate here! + $status = &mt('All'); } else { $status = $statushash{$msgstatus}; } @@ -299,7 +299,7 @@ sub scrollbuttons { ''.&mt('Page').': '. ''. ''. - ' of '.$maxdis. + ' / '.$maxdis.' '. ''. '
'. &mt('[_1] messages: showing messages [_2] through [_3] of [_4].',$status,$first,$finish,$total).''; @@ -509,7 +509,6 @@ sub movemsg { sub discourse { my ($statushash) = @_; my ($result,$active,$previous,$future); - my $crstype = &Apache::loncommon::course_type(); my ($course_personnel, $current_members, $expired_members, @@ -525,20 +524,14 @@ sub discourse { \%defaultUsers, 1,"selectedusers",1,'email') ) { - my $bcc_curr_hdr; - if ($crstype eq 'Community') { - $bcc_curr_hdr = &mt('Bcc: community participants with current access'); - } else { - $bcc_curr_hdr = &mt('Bcc: course members with current access'); - } - $result .= '
' - .''.$bcc_curr_hdr.'' - .'' - .'
'; - $result .= $tmptext.'

'; - if (ref($statushash) eq 'HASH') { - $statushash->{'active'} = 1; - } + $result .= '
' + .&mt('Bcc: course members with current access') + .'' + .'
'; + $result .= $tmptext.'

'; + if (ref($statushash) eq 'HASH') { + $statushash->{'active'} = 1; + } } if ($tmptext = &Apache::lonselstudent::render_student_list($expired_members, "previoususers", @@ -546,20 +539,15 @@ sub discourse { \%defaultUsers, 1, "selectedusers",0,'email') ) { - my $bcc_prev_hdr; - if ($crstype eq 'Community') { - $bcc_prev_hdr = &mt('Bcc: community participants with expired access'); - } else { - $bcc_prev_hdr = &mt('Bcc: course members with expired access'); - } - $result .= '
' - .''.$bcc_prev_hdr.'' - .'' - .'
'; + $result .= '
' + .&mt('Bcc: course members with expired access') + .'' + .''; $result .= $tmptext.'

'; if (ref($statushash) eq 'HASH') { $statushash->{'previous'} = 1; } + } if ($tmptext = &Apache::lonselstudent::render_student_list($future_members, "futureusers", @@ -567,20 +555,15 @@ sub discourse { \%defaultUsers, 1, "selectedusers",0,'email') ) { - my $bcc_future_hdr; - if ($crstype eq 'Community') { - $bcc_future_hdr = &mt('Bcc: community participants with future access'); - } else { - $bcc_future_hdr = &mt('Bcc: course members with future access'); - } - $result .= '
' - .''.$bcc_future_hdr.'' - .'' - .'
'; + $result .= '
' + .&mt('Bcc: course members with future access') + .'' + .''; $result .= $tmptext.'
'; if (ref($statushash) eq 'HASH') { $statushash->{'future'} = 1; } + } return $result; } @@ -650,8 +633,9 @@ sub disgroup { if (ref($access_status) eq 'HASH') { $access_status->{$status} = $$numitems{$status}; } - $r->print('
'.$lt{$status}. - '
'. + $r->print('
'. + ''.$lt{$status}.''. + ''. ''. ''. @@ -746,16 +730,10 @@ sub groupmail_header { } &Apache::lonhtmlcommon::clear_breadcrumbs(); if ($refarg) { - my $brtitle; - if (&Apache::loncommon::course_type() eq 'Community') { - $brtitle = 'View community groups'; - } else { - $brtitle = 'View course groups'; - } &Apache::lonhtmlcommon::add_breadcrumb ({href=>"/adm/coursegroups", text=>"Groups", - title=>$brtitle}); + title=>"View course groups"}); } &Apache::lonhtmlcommon::add_breadcrumb ({href=>"/adm/$cdom/$cnum/$group/smppg?$refarg", @@ -850,11 +828,8 @@ sub discrit { } # Check to see if there were any messages. if ($result eq '') { - $result = - '

'. - &mt('You have no critical messages.'). - '

'. - ''.&mt('Select a course').'
'. + $result = "

".&mt('You have no critical messages.')."

". + ''.&mt('Select a course').'
'. ''.&mt('Communicate').''; } else { $r->print($header); @@ -1056,22 +1031,19 @@ ENDDISHEADER my $fsqs='&folder='.$folder; my @temp=&sortedmessages(\%blocked,$startblock,$endblock,\$numblocked,$folder,$msgstatus); my $totalnumber=$#temp+1; - if ($totalnumber < 1) { - $r->print('

'); if ($msgstatus eq '') { - $r->print(&mt('There are no messages in this folder.')); + $r->print('

'.&mt('Empty Folder').'

'); } elsif ($msgstatus eq 'replied') { - $r->print(&mt('You have not replied to any messages in this folder.')); + $r->print('

'.&mt('You have not replied to any messages in this folder.').'

'); } else { - $r->print(&mt('There are no '.lc($statushash{$msgstatus}).' messages in this folder.')); + $r->print('

'.&mt('There are no '.lc($statushash{$msgstatus}).' messages in this folder.').'

'); } - $r->print('

'); if ($numblocked > 0) { $r->print(&blocked_in_folder($numblocked,$startblock,$endblock, \%setters)); } - return; + return; } my $interdis = $env{'form.interdis'}; my $number=int($totalnumber/$interdis); @@ -1088,44 +1060,44 @@ ENDDISHEADER $r->print(''. '
'); + $r->print(''.&mt('Date').''); } else { - $r->print(''.&mt('Date').''); + $r->print(''.&mt('Date').''); } $r->print(''); + $r->print(''.&mt('Status').''); } else { - $r->print(''.&mt('Status').''); + $r->print(''.&mt('Status').''); } $r->print("\n"); my $suffix = &Apache::lonmsg::foldersuffix($folder); - my $count = $firstdis; + my $count = 0; for (my $n=$firstdis;$n<=$lastdis;$n++) { my ($sendtime,$shortsubj,$fromname,$fromdomain,$status,$origID, $description,$recv_name,$recv_domain)= @@ -1292,8 +1264,8 @@ sub compout { &printheader($r,'/adm/email?compose=multiforward', 'Forwarding Multiple Messages'); if ($multiforward > 1) { - $r->print(&mt('Each of the[_1] [quant,_2,message] [_3]you checked' - .' will be forwarded to the recipient(s) you select below.','',$multiforward,'') + $r->print(&mt('Each of the [quant,_1,message] you checked' + .' will be forwarded to the recipient(s) you select below.',$multiforward) .'
'); } else { $r->print(&mt('The message you checked will be forwarded to the recipient(s) you select below.').'
'); @@ -1338,34 +1310,22 @@ sub compout { if (&Apache::lonnet::allowed('srm',$env{'request.course.id'}) || &Apache::lonnet::allowed('srm',$env{'request.course.id'}. '/'.$env{'request.course.sec'})) { - my $crstype = &Apache::loncommon::course_type(); my $crithelp = Apache::loncommon::help_open_topic("Course_Critical_Message"); - my $rsstxt; - if (&Apache::loncommon::course_type() eq 'Community') { - $rsstxt = &mt('Include in community RSS newsfeed'); - } else { - $rsstxt = &mt('Include in course RSS newsfeed'); - } $dispcrit= ''.$crithelp.'  '.&mt('Require return receipt?').'  
'. '
'. '
'; + &mt('Include in course RSS newsfeed').'
'; } if ($broadcast ne 'group') { if (&Apache::lonnet::allowed('dff',$env{'request.course.id'}) || &Apache::lonnet::allowed('dff',$env{'request.course.id'}. '/'.$env{'request.course.sec'})) { - my $rectxt; - if (&Apache::loncommon::course_type() eq 'Community') { - $rectxt = &mt("Include in community's 'User records' for recipient(s)"); - } else { - $rectxt = &mt("Include in course's 'User records' for recipient(s)"); - } + $dispcrit.='
'; } } @@ -1743,7 +1703,7 @@ sub additional_rec_row { my $bcc = &mt('Bcc:'); my $exmpl = &mt('username:domain,username:domain,...'); my $output = <<"ENDADD"; -
 '); if ($env{'form.sortedby'} eq "revdate") { - $r->print(''.&mt('Date').''); if ($env{'form.sortedby'} eq "revuser") { - $r->print(''.&mt('Username').''); + $r->print(''.&mt('Username').''); } else { - $r->print(''.&mt('Username').''); + $r->print(''.&mt('Username').''); } $r->print(''); if ($env{'form.sortedby'} eq "revdomain") { - $r->print(''.&mt('Domain').''); + $r->print(''.&mt('Domain').''); } else { - $r->print(''.&mt('Domain').''); + $r->print(''.&mt('Domain').''); } $r->print(''); if ($env{'form.sortedby'} eq "revsubject") { - $r->print(''.&mt('Subject').''); + $r->print(''.&mt('Subject').''); } else { - $r->print(''.&mt('Subject').''); + $r->print(''.&mt('Subject').''); } $r->print(''); if ($env{'form.sortedby'} eq "revcourse") { - $r->print(''.&mt('Course').''); + $r->print(''.&mt('Course').''); } else { - $r->print(''.&mt('Course').''); + $r->print(''.&mt('Course').''); } $r->print(''); if ($env{'form.sortedby'} eq "revstatus") { - $r->print(''.&mt('Status').'
$lt->{'ad'} ($exmpl): + @@ -1838,9 +1798,7 @@ sub disfacetoface { foreach my $key (sort(keys(%records))) { my %content=&Apache::lonmsg::unpackagemsg($records{$key}); next if ($content{'senderdomain'} eq ''); - if (!&Apache::lonfeedback::contains_block_html($content{'message'})) { - &Apache::lonfeedback::newline_to_br(\$content{'message'}); - } + &Apache::lonfeedback::newline_to_br(\$content{'message'}); if ($content{'subject'}=~/^Record/) { $result.='

'.&mt('Record').'

'; } elsif ($content{'subject'}=~/^Broadcast/) { @@ -1929,7 +1887,7 @@ sub facetoface { } my $crstype = &Apache::loncommon::course_type(); my $leaders = ($crstype eq 'Community') ? 'coordinators and leaders' - : 'faculty and staff'; + : 'faculty and staff'; &printheader($r, '/adm/email?recordftf=query', "User Notes, Face-to-Face, Critical Messages, Broadcast Messages, Archived Messages"); @@ -1966,7 +1924,6 @@ sub facetoface { .&Apache::lonhtmlcommon::end_pick_box() .'
' .'' - .'' ); if (($stage ne 'query') && @@ -2016,18 +1973,12 @@ sub examblock { $r->print('Not allowed'); return; } - my $usertype; - my $crstype = &Apache::loncommon::course_type(); - if ($crstype eq 'Community') { - $usertype = 'members'; - } else { - $usertype = 'students'; - } - my $lctype = lc($crstype); + my $usertype = (&Apache::loncommon::course_type() eq 'Community') ? 'members' + : 'students'; my %lt=&Apache::lonlocal::texthash( 'comb' => 'Communication Blocking', 'cbds' => 'Communication blocking during scheduled exams', - 'desc' => "You can use communication blocking to prevent $usertype enrolled in this $lctype from displaying LON-CAPA messages sent by other $usertype during an online exam. As blocking of communication could potentially interrupt legitimate communication between $usertype who are also both enrolled in a different LON-CAPA course or community, please be careful that you select the correct start and end times for your scheduled exam when setting or modifying these parameters.", + 'desc' => "You can use communication blocking to prevent $usertype enrolled in this course from displaying LON-CAPA messages sent by other $usertype during an online exam. As blocking of communication could potentially interrupt legitimate communication between $usertype who are also both enrolled in a different LON-CAPA course, please be careful that you select the correct start and end times for your scheduled exam when setting or modifying these parameters.", 'mecb' => 'Modify existing communication blocking periods', 'ncbc' => 'No communication blocks currently saved', 'stor' => 'Save', @@ -2204,7 +2155,7 @@ sub display_blocker_status { - + END foreach my $record (sort(keys(%{$records}))) { @@ -2224,7 +2175,7 @@ END $setuname,$setudom); $r->print(&Apache::loncommon::start_data_table_row()); $r->print(<<"END"); - + - + - + END $r->print(&Apache::loncommon::start_data_table_row()); @@ -2290,13 +2236,11 @@ END - + + END $r->print(&Apache::loncommon::end_data_table_row()); $r->print(&Apache::loncommon::end_data_table()); @@ -2332,7 +2276,7 @@ sub displaymessage { if ( $blocked{$msgid} eq 'ON' ) { &printheader($r,'/adm/email',&mt('Display a Message')); $r->print(&mt('You attempted to display a message that is currently blocked because you are enrolled in one or more courses for which there is an ongoing online exam.')); - $r->print(&Apache::loncommon::build_block_table($startblock,$endblock,\%setters)); + &build_block_table($r,$startblock,$endblock,\%setters); return; } if ($msgstatus eq '') { @@ -2369,10 +2313,6 @@ sub displaymessage { &printheader($r,'/adm/email?display='.&escape($msgid),'Display a Message','',$content{'baseurl'}); my %courseinfo=&Apache::lonnet::coursedescription($content{'courseid'}); -# Functions and Actions - my $li_start='• '; - my $li_end=' '; - # Prepare available functions my @functionlist; if (!$content{'noreplies'}) { @@ -2402,20 +2342,6 @@ sub displaymessage { .&mt('Next') .''); } -# Print functions - my $legendtext='' - .&mt('Functions') - .''; - my $showfunctionlist = $li_start.join($li_end.$li_start,@functionlist).$li_end; - $r->print('
' - .'
' - .'' - .$legendtext - .'' - .$showfunctionlist - .'
' - .'
' - ); # Prepare available actions my $symb; @@ -2424,8 +2350,8 @@ sub displaymessage { } elsif (defined($content{'baseurl'})) { $symb=&Apache::lonnet::symbread($content{'baseurl'}); } - if ($env{'user.adv'}) { my @actionlist; + if ($env{'user.adv'}) { if (&Apache::lonnet::allowed('vgr',$env{'request.course.id'})) { push(@actionlist,&Apache::loncommon::track_student_link( @@ -2450,23 +2376,31 @@ sub displaymessage { ,$symb ,'check')); } + } + +# Print functionlist and actionlist in page header + my $functions='
'; -# Print actions + # Functionlist + $functions.=&Apache::lonhtmlcommon::start_funclist(); + foreach my $item (@functionlist) { + $functions.=&Apache::lonhtmlcommon::add_item_funclist($item); + } + $functions .= &Apache::lonhtmlcommon::end_funclist(); + + # Actionlist if (@actionlist) { - my $showactionlist = $li_start.join($li_end.$li_start,@actionlist).$li_end; - $legendtext=&mt('[_1]Currently available actions[_2] (will open extra window):' - ,'',''); - $r->print('
' - .'
' - .'' - .$legendtext - .'' - .$showactionlist - .'
' - .'
' - ); + my $legendtext=&mt('Currently available actions (will open extra window)'); + $functions.=&Apache::lonhtmlcommon::start_funclist($legendtext); + foreach my $item (@actionlist) { + $functions.=&Apache::lonhtmlcommon::add_item_funclist($item); + } + $functions.=&Apache::lonhtmlcommon::end_funclist(); } - } + + $functions.='
'; + $r->print(&Apache::loncommon::head_subbox($functions)); + my ($tonum,$tolist,$cclist,$bcclist,$groupcclist,%recipients); if ($content{'recipid'}) { @@ -2621,14 +2555,12 @@ sub displaymessage { } if ($content{'group'} ne '') { if (&check_group_priv($content{'group'})) { - 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() - ); - } + $groupcclist = join(', ',@{$recipients{'group_cc_broadcast'}}); + if ($groupcclist) { + $r->print(&Apache::lonhtmlcommon::row_title(&mt('Group Cc')) + .$groupcclist + .&Apache::lonhtmlcommon::row_closure() + ); } } } @@ -2896,10 +2828,10 @@ sub header { if ($baseurl) { $extra .= ""; } - $r->print(&Apache::loncommon::start_page('Messages', + $r->print(&Apache::loncommon::start_page('Communication', $extra)); $r->print(&Apache::lonhtmlcommon::breadcrumbs - (($title?$title:'Send and display messages'))); + (($title?$title:'Send and Receive Messages'))); } # ---------------------------------------------------------------- Print header @@ -3152,7 +3084,7 @@ sub sendoffmail { my ($recuname,$recdomain)=split(/\:/,$address); my $msgtxt = $savemsg; if ($toaddr{$address}) { - $msgtxt.="\n".'
'."\n".$toaddr{$address}; + $msgtxt.='
'.$toaddr{$address}; } my @thismsg; if ($msgtype eq 'critical') { @@ -3259,9 +3191,8 @@ sub sendoffmail { } if (!$env{'form.multiforward'}) { if ($sendstatus=~/^(\s*(?:ok|con_delayed)\s*)*$/) { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Completed.')); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print('
'.&mt('Completed.'). + ''); if ($env{'form.displayedcrit'}) { &discrit($r); } @@ -3271,15 +3202,10 @@ sub sendoffmail { &Apache::loncommunicate::menu($r); } } else { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Could not deliver message'),1); - $message .= '
'.&mt('Please use the browser "Back" button and correct the recipient addresses ([_1]).',$sendstatus); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print('

'.&Apache::lonhtmlcommon::confirm_success(&mt('Could not deliver message'),1).'
'. + &mt('Please use the browser "Back" button and correct the recipient addresses ([_1]).',$sendstatus).'

'); } } - } else { - &printheader($r,'','Messages cancelled.'); - return 'cancelled'; } return $sendstatus; } @@ -3315,7 +3241,7 @@ sub handler { &Apache::lonhtmlcommon::clear_breadcrumbs(); &Apache::lonhtmlcommon::add_breadcrumb ({href=>"/adm/communicate", - text=>"Messages", + text=>"Communication/Messages", faq=>12,bug=>'Communication Tools',}); # ------------------------------------------------------------------ Get Folder @@ -3396,10 +3322,9 @@ sub handler { my ($result,$msg) = &statuschange($env{'form.markdel'},'deleted',$folder); if (!$result) { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete the message.'),1); - $message .= '

'.$msg.'

'; - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print('

'. + &mt('Failed to delete the message.').'

'. + '

'.$msg."

\n"); } &Apache::loncommunicate::menu($r); &disall($r,($folder?$folder:$dismode),$msgstatus); @@ -3421,9 +3346,7 @@ sub handler { $total ++; } &printheader($r,'','Marked Messages Read'); - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Marked [quant,_1,message] read',$total)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Marked [_1] message(s) read',$total).'

'); &Apache::loncommunicate::menu($r); &disall($r,($folder?$folder:$dismode),$msgstatus); } elsif ($env{'form.markedaction'} eq 'markedunread') { @@ -3434,9 +3357,7 @@ sub handler { $total ++; } &printheader($r,'','Marked Messages Unread'); - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Marked [quant,_1,message] unread',$total)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Marked [_1] message(s) unread',$total).'

'); &Apache::loncommunicate::menu($r); &disall($r,($folder?$folder:$dismode),$msgstatus); } elsif ($env{'form.markedaction'} eq 'markedmove') { @@ -3459,16 +3380,15 @@ sub handler { push(@failed_msg,$msg); } } - my $message; - if ($failed) { - $message = &Apache::lonhtmlcommon::confirm_success(&mt('Failed to move [quant,_1,message]',$failed),1); - $message .= '

'. - join("

\n

",@failed_msg). - "

\n"; - } - $message .= &Apache::lonhtmlcommon::confirm_success(&mt('Moved [quant,_1,message]',$total)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + if ($failed) { + $r->print('

+ '.&mt('Failed to move [_1] message(s)',$failed). + '

'); + $r->print('

'. + join("

\n

",@failed_msg). + "

\n"); + } + $r->print(&mt('Moved [_1] message(s)',$total).'

'); } &Apache::loncommunicate::menu($r); &disall($r,($folder?$folder:$dismode),$msgstatus); @@ -3486,16 +3406,15 @@ sub handler { } } &printheader($r,'','Deleted Messages'); - my $message; if ($failed) { - $message = &Apache::lonhtmlcommon::confirm_success(&mt('Failed to delete [quant,_1,message]',$failed),1); - $message .= '

'. + $r->print('

+ '.&mt('Failed to delete [_1] message(s)',$failed). + '

'); + $r->print('

'. join("

\n

",@failed_msg). - "

\n"; + "

\n"); } - $message .= &Apache::lonhtmlcommon::confirm_success(&mt('Deleted [quant,_1,message]',$total)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Deleted [_1] message(s)',$total).'

'); &Apache::loncommunicate::menu($r); &disall($r,($folder?$folder:$dismode),$msgstatus); } elsif ($env{'form.markunread'}) { @@ -3551,19 +3470,19 @@ sub handler { } if (keys(%forwardok) > 0) { my $count = keys(%forwardok); - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('[quant,_1,message] forwarded.',$count)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print('
'. + &mt('[quant,_1,message] forwarded.',$count). + ''); } if (keys(%forwardfail) > 0) { my $count = keys(%forwardfail); - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Could not forward [quant,_1,message].',$count),1); + $r->print('

'. + &mt('Could not forward [quant,_1,message].',$count). + ' '); foreach my $key (keys(%forwardfail)) { - $message .= '
'.&mt('Could not deliver forwarded message.').' '. - &mt('The recipient addresses may need to be corrected').' ('.$forwardfail{$key}.')'; + $r->print(&mt('Could not deliver forwarded message.').' '. + &mt('The recipient addresses may need to be corrected').' ('.$forwardfail{$key}.').

'); } - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); } &Apache::loncommunicate::menu($r); } else { @@ -3587,13 +3506,10 @@ sub handler { my $showfolder = $env{'form.newfolder'}; my ($makeresult,$warning) = &makefolder($env{'form.newfolder'}); if ($makeresult eq 'ok') { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" created.',$showfolder)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Folder "[_1]" created.',$showfolder).'
'); } else { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Creation failed.').' '.$makeresult.'
'.$warning,1); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Creation failed.').' '.$makeresult.'
'. + $warning); $showfolder = $folder; } &Apache::loncommunicate::menu($r); @@ -3605,14 +3521,10 @@ sub handler { my $showfolder = ''; my $delresult = &deletefolder($folder); if ($delresult eq 'ok') { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" deleted.',$folder)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Folder "[_1]" deleted.',$folder).'
'); $env{'form.folder'} = ''; } else { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Deletion failed.').' '.$delresult,1); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Deletion failed.').' '.$delresult.'
'); $showfolder = $folder; } &Apache::loncommunicate::menu($r); @@ -3622,13 +3534,9 @@ sub handler { my $showfolder = $env{'form.renamed'}; my $renresult = &renamefolder($folder); if ($renresult eq 'ok') { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Folder "[_1]" renamed to "[_2]".',$folder,$showfolder)); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Folder "[_1]" renamed to "[_2]".',$folder,$showfolder).'
'); } else { - my $message = &Apache::lonhtmlcommon::confirm_success(&mt('Renaming failed.').' '.$renresult,1); - $message = &Apache::loncommon::confirmwrapper($message); - $r->print($message); + $r->print(&mt('Renaming failed.').' '.$renresult.'
'); $showfolder = $folder; } &Apache::loncommunicate::menu($r);

$lt->{'ad'} ($exmpl)
 $lt->{'to'}
 $cc
 $bcc
$ltext->{'setb'} $ltext->{'even'} $ltext->{'blck'}$ltext->{'actn'}$ltext->{'actn'}?
$ltext->{'star'}: $startform
$ltext->{'endd'}:  $endform
$ltext->{'star'}: $startform
$ltext->{'endd'}:  $endform
$settername @@ -2234,16 +2185,11 @@ END if ($blocks->{$block} eq 'on') { $blockstatus = 'checked="checked"'; } - $r->print('
'); + $r->print('
'); } $r->print(<<"END"); -

- +

END $r->print(&Apache::loncommon::end_data_table_row()); $parmcount++; @@ -2280,7 +2226,7 @@ END
$ltext->{'dura'} $ltext->{'even'} $lt{'exam'} $ltext->{'blck'}$ltext->{'actn'}$ltext->{'actn'}?
END foreach my $block (@{$typeorder}) { - $r->print('
'); + $r->print('
'); } $r->print(<<"END"); -