--- loncom/publisher/loncfile.pm 2005/11/09 09:06:59 1.74 +++ loncom/publisher/loncfile.pm 2006/04/10 22:47:18 1.75 @@ -9,7 +9,7 @@ # and displays a page showing the results of the action. # # -# $Id: loncfile.pm,v 1.74 2005/11/09 09:06:59 www Exp $ +# $Id: loncfile.pm,v 1.75 2006/04/10 22:47:18 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1273,10 +1273,12 @@ sub handler { &Apache::loncommon::content_type($r,'text/html'); $r->send_http_header; + my (%loaditem,$js); + if ( ($env{'form.action'} eq 'newdir') && ($env{'form.phase'} eq 'two') && ( ($env{'form.callingmode'} eq 'testbank') || ($env{'form.callingmode'} eq 'imsimport') ) ) { my $newdirname = $env{'form.newfilename'}; - $r->print('LON-CAPA Construction Space - |); - my $loaditem = 'onLoad="writeDone()"'; - $r->print(&Apache::loncommon::bodytag('Construction Space File Operation','',$loaditem)); - } else { - $r->print('LON-CAPA Construction Space'); - $r->print(&Apache::loncommon::bodytag('Construction Space File Operation')); +|; + $loaditem{'onload'} => "writeDone()"; } - + + $r->print(&Apache::loncommon::start_page('Construction Space File Operation', + $js, + {'add_entries' => \%loaditem,})); $r->print('

'.&mt('Location').': '.&display($fn).'

'); @@ -1325,7 +1326,8 @@ function writeDone() { $env{'form.action'} eq 'Select Action' ) { $r->print('

'.&mt('New Resource').'

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

'.&mt('Unknown Action').' '.$env{'form.action'}.'

'); + $r->print('

'.&mt('Unknown Action').' '.$env{'form.action'}.'

'. + &Apache::loncommon::end_page()); return OK; } if ($env{'form.phase'} eq 'two') { @@ -1336,7 +1338,7 @@ function writeDone() { &phaseone($r,$fn,$uname,$udom); } - $r->print(''); + $r->print(&Apache::loncommon::end_page()); return OK; }