[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

albertel lon-capa-cvs@mail.lon-capa.org
Fri, 05 Aug 2005 19:46:26 -0000


albertel		Fri Aug  5 15:46:26 2005 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - BUG# 4269, relative img refs were not prointing in <randomlabel>
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.648 loncom/lonnet/perl/lonnet.pm:1.649
--- loncom/lonnet/perl/lonnet.pm:1.648	Tue Jul 26 09:30:34 2005
+++ loncom/lonnet/perl/lonnet.pm	Fri Aug  5 15:46:22 2005
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.648 2005/07/26 13:30:34 raeburn Exp $
+# $Id: lonnet.pm,v 1.649 2005/08/05 19:46:22 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -5644,6 +5644,9 @@
     if ($file=~m:^/~:) { # is a contruction space reference
         $location = $file;
         $location =~ s:/~(.*?)/(.*):/home/$1/public_html/$2:;
+    } elsif ($file=~m:^/home/[^/]*/public_html/:) {
+	# is a correct contruction space reference
+        $location = $file;
     } elsif ($file=~/^\/*(uploaded|editupload)/) { # is an uploaded file
         my ($udom,$uname,$filename)=
   	    ($file=~m -^/+(?:uploaded|editupload)/+([^/]+)/+([^/]+)/+(.*)$-);