[LON-CAPA-cvs] cvs: loncom /interface lonhelper.pm

www www at source.lon-capa.org
Sat Nov 5 18:42:14 EDT 2011


www		Sat Nov  5 22:42:14 2011 EDT

  Modified files:              
    /loncom/interface	lonhelper.pm 
  Log:
  Being able to list directories in construction space again
  
  
Index: loncom/interface/lonhelper.pm
diff -u loncom/interface/lonhelper.pm:1.185 loncom/interface/lonhelper.pm:1.186
--- loncom/interface/lonhelper.pm:1.185	Mon Oct 31 01:20:05 2011
+++ loncom/interface/lonhelper.pm	Sat Nov  5 22:42:14 2011
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # .helper XML handler to implement the LON-CAPA helper
 #
-# $Id: lonhelper.pm,v 1.185 2011/10/31 01:20:05 raeburn Exp $
+# $Id: lonhelper.pm,v 1.186 2011/11/05 22:42:14 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -2976,8 +2976,11 @@
     # If the subdirectory is in local CSTR space
     my $metadir;
     my $londocroot = $Apache::lonnet::perlvar{'lonDocRoot'};
-    if ($subdir =~ m{^\Q$londocroot/priv/\E[^/]+/[^/]+/(.*)$}) {
+    if ($subdir =~ m{^(?:\Q$londocroot\E)*/priv/[^/]+/[^/]+/(.*)$}) {
         my $innerpath=$1;
+        unless ($subdir=~m{^\Q$londocroot\E}) {
+           $subdir=$londocroot.$subdir;
+        }
 	my ($user,$domain)= 
 	    &Apache::loncacc::constructaccess($subdir);
 	$metadir='/res/'.$domain.'/'.$user.'/'.$innerpath;




More information about the LON-CAPA-cvs mailing list