[LON-CAPA-cvs] cvs: loncom /xml lonplot.pm scripttag.pm

matthew lon-capa-cvs@mail.lon-capa.org
Thu, 25 Apr 2002 17:25:36 -0000


matthew		Thu Apr 25 13:25:36 2002 EDT

  Modified files:              
    /loncom/xml	lonplot.pm scripttag.pm 
  Log:
  Filename change to help with printing.
  
  
Index: loncom/xml/lonplot.pm
diff -u loncom/xml/lonplot.pm:1.68 loncom/xml/lonplot.pm:1.69
--- loncom/xml/lonplot.pm:1.68	Thu Apr 25 13:23:10 2002
+++ loncom/xml/lonplot.pm	Thu Apr 25 13:25:36 2002
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Dynamic plot
 #
-# $Id: lonplot.pm,v 1.68 2002/04/25 17:23:10 sakharuk Exp $
+# $Id: lonplot.pm,v 1.69 2002/04/25 17:25:36 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -484,14 +484,14 @@
 	## Determine filename
 	my $tmpdir = '/home/httpd/perl/tmp/';
 	my $filename = $ENV{'user.name'}.'_'.$ENV{'user.domain'}.
-	    '_'.time.'_'.$$.$randnumber.'_plot.data';
+	    '_'.time.'_'.$$.$randnumber.'_plot';
 	## Write the plot description to the file
 	&write_gnuplot_file($tmpdir,$filename,$target);
 	$filename = &Apache::lonnet::escape($filename);
 	## return image tag for the plot
 	if ($target eq 'web') {
 	    $result .= <<"ENDIMAGE";
-<img src    = "/cgi-bin/plot.gif?file=$filename&output=gif" 
+<img src    = "/cgi-bin/plot.gif?file=$filename.data&output=gif" 
      width  = "$plot{'width'}"
      height = "$plot{'height'}"
      align  = "$plot{'align'}"
Index: loncom/xml/scripttag.pm
diff -u loncom/xml/scripttag.pm:1.70 loncom/xml/scripttag.pm:1.71
--- loncom/xml/scripttag.pm:1.70	Wed Apr 10 11:21:29 2002
+++ loncom/xml/scripttag.pm	Thu Apr 25 13:25:36 2002
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # <script> definiton
 #
-# $Id: scripttag.pm,v 1.70 2002/04/10 15:21:29 albertel Exp $
+# $Id: scripttag.pm,v 1.71 2002/04/25 17:25:36 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -256,6 +256,7 @@
     # FIXME this probably needs to be smart about construction vs.
     # non construction space.
     my $location=&Apache::lonnet::filelocation($Apache::lonxml::pwd['-1'],$bodytext);
+    &Apache::lonnet::logthis("$location,$Apache::lonxml::pwd['-1'],$bodytext");
     my $file=&Apache::lonnet::getfile($location);
     if ($file == -1) {
       &Apache::lonxml::error("<b> Unable to find <i>$bodytext as $location</i> for import</b>");