[LON-CAPA-cvs] cvs: loncom /interface lonprintout.pm
sakharuk
lon-capa-cvs@mail.lon-capa.org
Mon, 20 Oct 2003 17:38:51 -0000
sakharuk Mon Oct 20 13:38:51 2003 EDT
Modified files:
/loncom/interface lonprintout.pm
Log:
Bug 1863 is fixed - cookie mechanism is impemented. Needs big cleanup - doing now.
Index: loncom/interface/lonprintout.pm
diff -u loncom/interface/lonprintout.pm:1.255 loncom/interface/lonprintout.pm:1.256
--- loncom/interface/lonprintout.pm:1.255 Wed Oct 15 14:01:10 2003
+++ loncom/interface/lonprintout.pm Mon Oct 20 13:38:51 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Printout
#
-# $Id: lonprintout.pm,v 1.255 2003/10/15 18:01:10 www Exp $
+# $Id: lonprintout.pm,v 1.256 2003/10/20 17:38:51 sakharuk Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1074,11 +1074,22 @@
unless ($temp_file = Apache::File->new('>'.$filename)) {
$r->log_error("Couldn't open $filename for output $!");
return SERVER_ERROR;
- }
+ }
+
+########
+ my $identifier = time.'_'.int(rand(1000));
+ &Apache::lonnet::appenv($identifier.'.file' => $filename,
+ $identifier.'.layout' => $laystyle,
+ $identifier.'.numcol' => $numberofcolumns,
+ $identifier.'.selection' => $selectionmade);
+
+##<meta http-equiv="Refresh" content="0; url=/cgi-bin/printout.pl?$filename&$laystyle&$numberofcolumns&$selectionmade">
+########
+
print $temp_file $result;
$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?$identifier">
</body>
</html>
FINALEND