--- loncom/publisher/testbankimport.pm 2008/09/24 19:48:29 1.18 +++ loncom/publisher/testbankimport.pm 2009/05/06 13:13:00 1.23 @@ -1,5 +1,5 @@ # Handler for parsing text upload problem descriptions into .problems -# $Id: testbankimport.pm,v 1.18 2008/09/24 19:48:29 raeburn Exp $ +# $Id: testbankimport.pm,v 1.23 2009/05/06 13:13:00 bisitz Exp $ # # Copyright Michigan State University Board of Trustees # @@ -81,14 +81,14 @@ function createWin() { newWindow = window.open("","CreateDir","HEIGHT=400,WIDTH=750,scrollbars=yes") newWindow.document.open() newWindow.document.write('$start_page') - newWindow.document.write("[Author Header]\\n") + newWindow.document.write("[Author Header]\\n") newWindow.document.write("

$lt{'loca'}: $webpath

$lt{'newd'}

\\n") newWindow.document.write("
\\n") newWindow.document.write("$lt{'ente'}.

") - newWindow.document.write("") - newWindow.document.write("") - newWindow.document.write("") - newWindow.document.write("$webpath") + newWindow.document.write("") + newWindow.document.write("") + newWindow.document.write("") + newWindow.document.write("$webpath") newWindow.document.write("
") newWindow.document.write('$end_page') newWindow.document.close() @@ -510,7 +510,7 @@ sub display_zero {
'. &topic_bar(1,&mt('Optional: create a sub-directory in which the testbank questions will be saved')). &mt('By default, LON-CAPA problems generated from the testbank file will be stored in the current directory.').' '.&mt('To store them in a new sub-directory:'). - ' '. + ' '. &page_footer($env{'form.newdir'},$uname,$fn,$page,$webpath).'
'); } @@ -522,7 +522,7 @@ sub display_one { my %topics; $topics{2} = &mt('Select the format of the question number - e.g., 1, 1., 1), (1 or (1) - ').'   '."\n". - '  '."\n". + '  '."\n". ' '."\n". + ''."\n". ''.$qtype[$i].''."\n". ''. ''.$showqn.'

'."\n"); @@ -829,7 +829,7 @@ sub display_three { } $r->print(&Apache::loncommon::start_data_table_row(). ''.$qnum.''."\n". - ''."\n". + ''."\n". ''.$qtype[$i].''."\n". ''."\n". ''.$items->[$j].''."\n". @@ -1200,7 +1200,7 @@ sub page_footer { $output .= '   - + '; } $output .= ' @@ -1773,8 +1773,9 @@ sub print_header { my $output = &Apache::loncommon::start_page($title,$javascript, {'add_entries' => $loadentries}); if (($uname ne $env{'user.name'}) || ($udom ne $env{'user.domain'})) { - $output .= '

'.&mt('Co-Author').': '.$uname. - &mt(' at ').$udom.'

'; + $output .= '

' + .&mt('Co-Author [_1]:[_2]',$uname,$udom) + .'

'; } return $output; } @@ -1817,7 +1818,7 @@ sub handler { my ($fn,$filename); if ($env{'form.filename'}) { $fn=$env{'form.filename'}; - $fn=~s/^http\:\/\/[^\/]+\///; + $fn=~s/^https?\:\/\/[^\/]+\///; $fn=~s/^\///; $fn=~s{(~|priv/)($LONCAPA::username_re)}{}; $fn=~s/\/+/\//g;