--- loncom/interface/lonprintout.pm 2007/04/20 20:33:35 1.499 +++ loncom/interface/lonprintout.pm 2007/07/04 14:17:36 1.502 @@ -2,7 +2,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.499 2007/04/20 20:33:35 foxr Exp $ +# $Id: lonprintout.pm,v 1.502 2007/07/04 14:17:36 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -60,19 +60,13 @@ sub fetch_raw_resource { my ($url) = @_; my $filename = &Apache::lonnet::filelocation("", $url); - # - # fetch if needed: - # - if (! -e $filename) { - my $repcopy_result = &Apache::lonnet::repcopy($filename); + my $contents = &Apache::lonnet::getfile($filename); - if ($repcopy_result ne 'ok') { - return "File open failed for $filename"; # This will bomb the print. - } + if ($contents == -1) { + return "File open failed for $filename"; # This will bomb the print. } - my $contents = &Apache::lonnet::readfile($filename); - return $contents; + } @@ -873,7 +867,11 @@ sub page_format_transformation { my ($textwidth,$textheight,$oddoffset,$evenoffset,$topmargin); if ($selectionmade eq '4') { - $assignment='Problems from the Whole Course'; + if ($choice eq 'all_problems') { + $assignment='Problems from the Whole Course'; + } else { + $assignment='Resources from the Whole Course'; + } } else { $assignment=&Apache::lonxml::latex_special_symbols($assignment,'header'); } @@ -2607,7 +2605,7 @@ CHOOSE_STUDENTS - Names to store the CODEs under for later: + Names to save the CODEs under for later: @@ -2718,7 +2716,7 @@ CHOOSE_STUDENTS1 - Names to store the CODEs under for later: + Names to save the CODEs under for later: