[LON-CAPA-cvs] cvs: loncom /publisher lonpublisher.pm

albertel lon-capa-cvs@mail.lon-capa.org
Sat, 03 Jul 2004 03:32:31 -0000


albertel		Fri Jul  2 23:32:31 2004 EDT

  Modified files:              
    /loncom/publisher	lonpublisher.pm 
  Log:
  - if a file consisted of 
  ...
  </body>
  </html>text
  
  (Basically text after the last html tag in the file)
  
  The <allow>s were never inserted.
  
  
  This should now insert the <allow>s in front of the last tag even if there is text after the last tag in the file
  
  (BUG#2995)
  
  
Index: loncom/publisher/lonpublisher.pm
diff -u loncom/publisher/lonpublisher.pm:1.174 loncom/publisher/lonpublisher.pm:1.175
--- loncom/publisher/lonpublisher.pm:1.174	Fri Jun 18 12:52:19 2004
+++ loncom/publisher/lonpublisher.pm	Fri Jul  2 23:32:30 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Publication Handler
 #
-# $Id: lonpublisher.pm,v 1.174 2004/06/18 16:52:19 www Exp $
+# $Id: lonpublisher.pm,v 1.175 2004/07/03 03:32:30 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -929,7 +929,7 @@
 	       }
            }
         }
-        $outstring=~s/\n*(\<\/[^\>]+\>)\s*$/$allowstr\n$1\n/s;
+        $outstring=~s/\n*(\<\/[^\>]+\>[^<]*)$/$allowstr\n$1\n/s;
 
 # ------------------------------------------------------------- Write modified.