--- loncom/homework/chemresponse.pm 2010/02/28 23:35:53 1.87 +++ loncom/homework/chemresponse.pm 2011/07/04 09:24:54 1.89 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # chemical equation style response # -# $Id: chemresponse.pm,v 1.87 2010/02/28 23:35:53 raeburn Exp $ +# $Id: chemresponse.pm,v 1.89 2011/07/04 09:24:54 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -116,7 +116,7 @@ CHEMJS 'bgcolor' => '#FFFFFF',}); my $end_page = &Apache::loncommon::end_page({'js_ready' => 1,}); - + my $java_not_enabled=&Apache::lonhtmlcommon::java_not_enabled(); my $body=< @@ -143,7 +143,7 @@ $js -You have to enable Java and JavaScript on your machine. +$java_not_enabled $molecule
@@ -417,7 +417,8 @@ sub start_organicstructure { $id=&escape($id); &Apache::lonxml::register_ssi("/cgi-bin/convertjme.pl?$id"); if ($options =~ /border/) { $result.= '\fbox{'; } - $result .= '\graphicspath{{/home/httpd/perl/tmp/}}\includegraphics[width='.$texwidth.' mm]{'.$filename.'.eps}'; + $result .= '\graphicspath{{'.LONCAPA::tempdir(). + '}}\includegraphics[width='.$texwidth.' mm]{'.$filename.'.eps}'; if ($options =~ /border/) { $result.= '} '; } } elsif ($target eq 'edit') { $result .=&Apache::edit::tag_start($target,$token);