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

albertel lon-capa-cvs@mail.lon-capa.org
Thu, 30 Mar 2006 20:16:19 -0000


albertel		Thu Mar 30 15:16:19 2006 EDT

  Modified files:              
    /loncom/homework	structuretags.pm 
  Log:
  - <library> should only emit the headers in CSTR when it's the top tag
  
  
Index: loncom/homework/structuretags.pm
diff -u loncom/homework/structuretags.pm:1.339 loncom/homework/structuretags.pm:1.340
--- loncom/homework/structuretags.pm:1.339	Wed Mar 29 17:41:32 2006
+++ loncom/homework/structuretags.pm	Thu Mar 30 15:16:14 2006
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA 
 # definition of tags that give a structure to a document
 #
-# $Id: structuretags.pm,v 1.339 2006/03/29 22:41:32 albertel Exp $
+# $Id: structuretags.pm,v 1.340 2006/03/30 20:16:14 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -942,8 +942,9 @@
     } elsif ($target eq 'modified') {
 	$result=$token->[4];
 	$result.=&Apache::edit::handle_insert();
-    } elsif ($target eq 'web' && $$tagstack[0] ne 'problem' &&
-	     $env{'request.state'} eq "construct" ) {
+    } elsif (($target eq 'web' || $target eq 'webgrade')
+	     && $$tagstack[0] eq 'library' 
+	     && $env{'request.state'} eq "construct" ) {
 	($result,$head_tag_start,$body_tag_start,$form_tag_start)=
 	    &page_start($target,$token,$tagstack,$parstack,$parser,$safeeval);
 	my $name=&get_resource_name($parstack,$safeeval);