[LON-CAPA-cvs] cvs: loncom /homework structuretags.pm

sakharuk lon-capa-cvs@mail.lon-capa.org
Thu, 17 Jul 2003 18:42:13 -0000


sakharuk		Thu Jul 17 14:42:13 2003 EDT

  Modified files:              
    /loncom/homework	structuretags.pm 
  Log:
  Changes in <tex> tag to avoid parsing content between <tex> </tex> for tex target. That's neccessary to print Ed's problems.
  
  
Index: loncom/homework/structuretags.pm
diff -u loncom/homework/structuretags.pm:1.197 loncom/homework/structuretags.pm:1.198
--- loncom/homework/structuretags.pm:1.197	Thu Jul 17 09:50:44 2003
+++ loncom/homework/structuretags.pm	Thu Jul 17 14:42:13 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA 
 # definition of tags that give a structure to a document
 #
-# $Id: structuretags.pm,v 1.197 2003/07/17 13:50:44 www Exp $
+# $Id: structuretags.pm,v 1.198 2003/07/17 18:42:13 sakharuk Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -57,12 +57,15 @@
 
 sub start_tex {
     my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_;
-    if (!($target eq 'tex' || $target eq 'edit' || $target eq 'modified' ||
+    my $result='';
+    if (!($target eq 'edit' || $target eq 'modified' ||
 	  $target eq 'answer' || $target eq 'grade' || $target eq 'meta' )) {
 	&Apache::lonxml::debug("tex 1");
 	my $bodytext=&Apache::lonxml::get_all_text("/tex",$parser);
+    } elsif ($target eq 'tex') {
+	$result=&Apache::lonxml::get_all_text("/tex",$parser);
     }
-    return '';
+    return $result;;
 }
 
 sub end_tex {