[LON-CAPA-cvs] cvs: loncom /xml lonplot.pm
matthew
lon-capa-cvs@mail.lon-capa.org
Thu, 28 Feb 2002 21:04:10 -0000
matthew Thu Feb 28 16:04:10 2002 EDT
Modified files:
/loncom/xml lonplot.pm
Log:
Changed tex rendering functionality to call plot.gif. Must use plot.gif
version 1.8 or greater.
Index: loncom/xml/lonplot.pm
diff -u loncom/xml/lonplot.pm:1.52 loncom/xml/lonplot.pm:1.53
--- loncom/xml/lonplot.pm:1.52 Wed Feb 27 17:17:06 2002
+++ loncom/xml/lonplot.pm Thu Feb 28 16:04:10 2002
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Dynamic plot
#
-# $Id: lonplot.pm,v 1.52 2002/02/27 22:17:06 matthew Exp $
+# $Id: lonplot.pm,v 1.53 2002/02/28 21:04:10 matthew Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -453,14 +453,15 @@
## return image tag for the plot
if ($target eq 'web') {
$result .= <<"ENDIMAGE";
-<img src = "/cgi-bin/plot.gif?$filename"
+<img src = "/cgi-bin/plot.gif?file=$filename&output=gif"
width = "$plot{'width'}"
height = "$plot{'height'}"
align = "$plot{'align'}"
alt = "image should be /cgi-bin/plot.gif?$filename" />
ENDIMAGE
} elsif ($target eq 'tex') {
- system "gnuplot $filename";
+ &Apache::lonnet::ssi('cgi-bin/plot.gif?file=$filename'.
+ '&output=eps');
$result = "$filename.eps";
}
} elsif ($target eq 'edit') {