[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Mon, 27 Mar 2006 23:00:22 -0000
albertel Mon Mar 27 18:00:22 2006 EDT
Modified files:
/loncom/lonnet/perl lonnet.pm
Log:
- better? way of cleaning up after clutter?
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.721 loncom/lonnet/perl/lonnet.pm:1.722
--- loncom/lonnet/perl/lonnet.pm:1.721 Sun Mar 26 16:20:55 2006
+++ loncom/lonnet/perl/lonnet.pm Mon Mar 27 18:00:18 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network
# TCP networking package
#
-# $Id: lonnet.pm,v 1.721 2006/03/26 21:20:55 banghart Exp $
+# $Id: lonnet.pm,v 1.722 2006/03/27 23:00:18 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -850,6 +850,7 @@
my ($r)=@_;
if (! $r->is_initial_req()) { return DECLINED; }
&purge_remembered();
+ #&Apache::loncommon::validate_page();
undef(%env);
return OK;
}
@@ -4739,7 +4740,14 @@
sub stat_file {
my ($uri) = @_;
- $uri = '/'.&declutter($uri);
+ $uri = &clutter($uri);
+
+ # we want just the url part without the unneeded accessor url bits
+ if ($file =~ m-^/adm/-) {
+ $file=~s-^/adm/wrapper/-/-;
+ $file=~s-^/adm/coursedocs/showdoc/-/-;
+ }
+
my ($udom,$uname,$file,$dir);
if ($uri =~ m-^/(uploaded|editupload)/-) {
($udom,$uname,$file) =