[LON-CAPA-cvs] cvs: loncom(version_1_0_1) /xml londefdef.pm

albertel lon-capa-cvs@mail.lon-capa.org
Fri, 22 Aug 2003 16:47:44 -0000


albertel		Fri Aug 22 12:47:44 2003 EDT

  Modified files:              (Branch: version_1_0_1)
    /loncom/xml	londefdef.pm 
  Log:
  - backport 1.164 1.165
  
  
Index: loncom/xml/londefdef.pm
diff -u loncom/xml/londefdef.pm:1.158 loncom/xml/londefdef.pm:1.158.4.1
--- loncom/xml/londefdef.pm:1.158	Fri Aug  1 09:35:20 2003
+++ loncom/xml/londefdef.pm	Fri Aug 22 12:47:44 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Tags Default Definition Module 
 #
-# $Id: londefdef.pm,v 1.158 2003/08/01 13:35:20 sakharuk Exp $
+# $Id: londefdef.pm,v 1.158.4.1 2003/08/22 16:47:44 albertel Exp $
 # 
 #
 # Copyright Michigan State University Board of Trustees
@@ -394,7 +394,7 @@
 }
 
 sub end_meta {
-    my ($target,$token,$tagstack,$parstack,$parser) = @_;
+    my ($target,$token,$tagstack,$parstack,$parser,$safeeval) = @_;
     my $currentstring = '';
     if ($target eq 'web') {
 	my $args='';
@@ -403,8 +403,11 @@
 	    $currentstring = $token->[4];
 	}
     } elsif ($target eq 'tex') {
-	$currentstring=&Apache::lonxml::endredirection();
-	$currentstring='';
+	my $content=&Apache::lonxml::get_param('content',$parstack,$safeeval);
+	my $name=&Apache::lonxml::get_param('name',$parstack,$safeeval);
+	if ((not defined $content) && (not defined $name)) {
+	    &Apache::lonxml::startredirection();
+	}
     }
     return $currentstring;
 }