Diff for /loncom/interface/lonprintout.pm between versions 1.142 and 1.143

version 1.142, 2003/05/02 14:17:57 version 1.143, 2003/05/02 15:48:26
Line 1389  ENDPART Line 1389  ENDPART
   
   
     if ($helper->{'VARS'}->{'PRINT_TYPE'} eq 'current_document') {      if ($helper->{'VARS'}->{'PRINT_TYPE'} eq 'current_document') {
       #-- single document - problem, page, html, xml, ...          #-- single document - problem, page, html, xml, ...
    my $currentURL;
    if (defined $helper->{'VARS'}->{'url'}) {
       $currentURL=$helper->{'VARS'}->{'url'};
    } else {
       $currentURL=$helper->{'VARS'}->{'postdata'};
    }
  $selectionmade = 1;   $selectionmade = 1;
  if ($helper->{'VARS'}->{'url'}=~/\.(problem|exam|quiz|assess|survey|form|library|page|xml|html|htm|xhtml|xhtm)$/) {   if ($currentURL=~/\.(problem|exam|quiz|assess|survey|form|library|page|xml|html|htm|xhtml|xhtm)$/) {
         my %moreenv;          my %moreenv;
         $moreenv{'form.grade_target'}='tex';          $moreenv{'form.grade_target'}='tex';
         if (&Apache::lonnet::allowed('bre',$helper->{'VARS'}->{'url'})) {   if (&Apache::lonnet::allowed('bre',$currentURL)) {
   $helper->{'VARS'}->{'url'}=~s/http:\/\/[^\/]+//;      $currentURL=~s/http:\/\/[^\/]+//;
         }   }
         $moreenv{'request.filename'}=$helper->{'VARS'}->{'url'};          $moreenv{'request.filename'}=$currentURL;
         $moreenv{'form.textwidth'}=$LaTeXwidth;          $moreenv{'form.textwidth'}=$LaTeXwidth;
         &Apache::lonnet::appenv(%moreenv);          &Apache::lonnet::appenv(%moreenv);
         my $texversion=&Apache::lonnet::ssi($helper->{'VARS'}->{'url'});          my $texversion=&Apache::lonnet::ssi($currentURL);
         &Apache::lonnet::delenv('form.grade_target','form.textwidth','form.counter');          &Apache::lonnet::delenv('form.grade_target','form.textwidth','form.counter');
         $result .= $texversion;          $result .= $texversion;
         if ($helper->{'VARS'}->{'url'}=~m/\.page\s*$/) {          if ($currentURL=~m/\.page\s*$/) {
   ($result,$number_of_columns) = &page_cleanup($result);    ($result,$number_of_columns) = &page_cleanup($result);
         }          }
       } else {        } else {
Line 1639  ENDPART Line 1645  ENDPART
     }       } 
     print $temp_file $result;      print $temp_file $result;
   
   #<meta http-equiv="Refresh" content="0; url=/cgi-bin/printout.pl?$filename&$laystyle&$numberofcolumns&$selectionmade">
 $r->print(<<FINALEND);  $r->print(<<FINALEND);
 <meta http-equiv="Refresh" content="0; url=/cgi-bin/printout.pl?$filename&$laystyle&$numberofcolumns&$selectionmade">  <meta http-equiv="Refresh" content="0; url=/cgi-bin/printout.pl?$filename&$laystyle&$numberofcolumns&$selectionmade">
 </body>  </body>

Removed from v.1.142  
changed lines
  Added in v.1.143


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>