--- loncom/xml/londefdef.pm 2005/04/07 06:56:27 1.267 +++ loncom/xml/londefdef.pm 2005/05/23 09:41:38 1.274 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Tags Default Definition Module # -# $Id: londefdef.pm,v 1.267 2005/04/07 06:56:27 albertel Exp $ +# $Id: londefdef.pm,v 1.274 2005/05/23 09:41:38 foxr Exp $ # # # Copyright Michigan State University Board of Trustees @@ -153,7 +153,7 @@ sub start_html { my $currentstring = ''; my $options=$env{'course.'.$env{'request.course.id'}.'.tthoptions'}; &Apache::lontexconvert::init_tth(); - if ($target eq 'web' || $target eq 'edit') { + if ($target eq 'web' || $target eq 'edit' || $target eq 'webgrade' ) { $currentstring = &Apache::lonxml::xmlbegin(); } elsif ($target eq 'tex') { $currentstring .= '\documentclass[letterpaper]{article}'; @@ -3854,9 +3854,11 @@ sub get_eps_image { #if replication failed try to find ps file $src=~s/\.eps$/\.ps/; &Apache::lonxml::debug("Now looking for $src"); - #if no ps file try to replicate it - if (not -e $src && - &Apache::lonnet::repcopy($src) ne 'ok') { + #if no ps file try to replicate it. + my $didrepcopy = &Apache::lonnet::repcopy($src); + &Apache::lonxml::debug("repcopy of $src ... $didrepcopy"); + if ( (not -e $src) || + ($didrepcopy ne 'ok')) { &Apache::lonxml::debug("Failed to find or replicate $src"); #if replication failed try to produce eps file dynamically