--- loncom/interface/lonprintout.pm 2010/08/23 20:53:09 1.583.2.1
+++ loncom/interface/lonprintout.pm 2010/09/02 00:17:36 1.583.2.3
@@ -2,7 +2,7 @@
# The LearningOnline Network
# Printout
#
-# $Id: lonprintout.pm,v 1.583.2.1 2010/08/23 20:53:09 raeburn Exp $
+# $Id: lonprintout.pm,v 1.583.2.3 2010/09/02 00:17:36 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1581,7 +1581,7 @@ sub print_page_in_course {
$form{'grade_target'} = 'tex';
$form{'textwidth'} = &get_textwidth($helper, $LaTeXwidth);
- $form{'pdfFormFields'} = $pdfFormFields; #
+ $form{'pdfFormFields'} = 'no';
$form{'showallfoils'} = $helper->{'VARS'}->{'showallfoils'};
$form{'problem_split'}=$parmhash{'problem_stream_switch'};
@@ -1685,8 +1685,8 @@ sub print_page_in_course {
# List of recently generated print files
#
sub recently_generated {
- my $r=shift;
- my $prtspool=$r->dir_config('lonPrtDir');
+ my ($prtspool) = @_;
+ my $output;
my $zip_result;
my $pdf_result;
opendir(DIR,$prtspool);
@@ -1719,10 +1719,10 @@ sub recently_generated {
if ($ext eq 'zip') { $zip_result .= $result; }
}
if ($zip_result || $pdf_result) {
- $r->print('
');
+ $output ='
';
}
if ($zip_result) {
- $r->print(''.&mt('Recently generated printout zip files')."
\n"
+ $output .=''.&mt('Recently generated printout zip files')."
\n"
.&Apache::loncommon::start_data_table()
.&Apache::loncommon::start_data_table_header_row()
.''.&mt('Download').' | '
@@ -1730,11 +1730,10 @@ sub recently_generated {
.''.&mt('File Size (Bytes)').' | '
.&Apache::loncommon::end_data_table_header_row()
.$zip_result
- .&Apache::loncommon::end_data_table()
- );
+ .&Apache::loncommon::end_data_table();
}
if ($pdf_result) {
- $r->print(''.&mt('Recently generated printouts')."
\n"
+ $output .=''.&mt('Recently generated printouts')."
\n"
.&Apache::loncommon::start_data_table()
.&Apache::loncommon::start_data_table_header_row()
.''.&mt('Download').' | '
@@ -1742,9 +1741,9 @@ sub recently_generated {
.''.&mt('File Size (Bytes)').' | '
.&Apache::loncommon::end_data_table_header_row()
.$pdf_result
- .&Apache::loncommon::end_data_table()
- );
+ .&Apache::loncommon::end_data_table();
}
+ return $output;
}
#
@@ -2090,7 +2089,7 @@ ENDPART
my %form;
$form{'grade_target'} = 'tex';
$form{'textwidth'} = &get_textwidth($helper, $LaTeXwidth);
- $form{'pdfFormFields'} = $pdfFormFields;
+ $form{'pdfFormFields'} = 'no';
# If form.showallfoils is set, then request all foils be shown:
# privilege will be enforced both by not allowing the
@@ -4129,10 +4128,12 @@ PROBTYPE
return $helper;
}
- $r->print($helper->display());
+ my $footer;
if ($helper->{STATE} eq 'START') {
- &recently_generated($r);
+ my $prtspool=$r->dir_config('lonPrtDir');
+ $footer = &recently_generated($prtspool);
}
+ $r->print($helper->display($footer));
&Apache::lonhelper::unregisterHelperTags();
return OK;
@@ -4208,9 +4209,6 @@ sub render {
my $PaperType=&mt('Paper type');
my $landscape=&mt('Landscape');
my $portrait=&mt('Portrait');
- my $pdfFormLabel=&mt('PDF-Formfields');
- my $with=&mt('with Formfields');
- my $without=&mt('without Formfields');
$result.=''.&mt('Layout Options').'
'
@@ -4219,7 +4217,6 @@ sub render {
.''.$PageLayout.' | '
.''.$NumberOfColumns.' | '
.''.$PaperType.' | '
- .''.$pdfFormLabel.' | '
.&Apache::loncommon::end_data_table_header_row()
.&Apache::loncommon::start_data_table_row()
.''
@@ -4260,12 +4257,6 @@ sub render {
$result .= <
|
-
-
- |
HTML
$result.=&Apache::loncommon::end_data_table_row()
.&Apache::loncommon::end_data_table();