--- loncom/interface/lonprintout.pm 2002/03/06 20:43:06 1.16 +++ loncom/interface/lonprintout.pm 2002/03/20 22:14:30 1.17 @@ -1,7 +1,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.16 2002/03/06 20:43:06 sakharuk Exp $ +# $Id: lonprintout.pm,v 1.17 2002/03/20 22:14:30 sakharuk Exp $ # # Copyright Michigan State University Board of Trustees # @@ -249,9 +249,12 @@ ENDPART m/.*\/(.*)/; $courseidinfo = $ENV{'course.physnet_'.$1.'.description'}; $result =~ s/\\documentclass\[letterpaper\]{article}/\\documentclass\[twocolumn\]{article}/; - $result =~ s/\\begin{document}/\\textheight 25\.9cm\\oddsidemargin = -0\.57in\\evensidemargin = -0\.57in\\textwidth= 7\.7in\\begin{document}\\voffset=-1\.8cm\\setcounter{page}{1}\\noindent\\fbox{\\textbf{$ENV{'environment.firstname'} $ENV{'environment.lastname'}}}\\hskip 1\.4in $courseidinfo\\newline\\noindent\\textit{Physics for Scientists and Engineers}\\newline\\noindent\\textbf{Due Thursday, March 7, 2002 at 8:00PM}\\vskip 5 mm/; + $result =~ s/\\begin{document}/\\textheight 25\.9cm\\oddsidemargin = -0\.57in\\evensidemargin = -0\.57in\\textwidth= 7\.7in\\begin{document}\\voffset=-1\.8cm\\setcounter{page}{1}\\noindent\\fbox{\\textbf{$ENV{'environment.firstname'} $ENV{'environment.lastname'}}}\\hskip 1\.4in $courseidinfo \\vskip 5 mm /; $result =~ s/\\includegraphics/\\includegraphics\[width=9\.0 cm\]/g; } +#-- LaTeX corrections + $result =~ s/^\s+$//gm; #remove empty lines + $result =~ s/%/\\%/g; #corrects % #-- writing .tex file in prtspool my $temp_file; $filename = "/home/httpd/prtspool/$ENV{'environment.firstname'}$ENV{'environment.lastname'}temp$ENV{'user.login.time'}.tex";