[LON-CAPA-cvs] cvs: loncom /interface londocs.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Thu, 01 Sep 2005 23:20:06 -0000
albertel Thu Sep 1 19:20:06 2005 EDT
Modified files:
/loncom/interface londocs.pm
Log:
- actually fuix 4290
Index: loncom/interface/londocs.pm
diff -u loncom/interface/londocs.pm:1.204 loncom/interface/londocs.pm:1.205
--- loncom/interface/londocs.pm:1.204 Wed Aug 31 02:36:41 2005
+++ loncom/interface/londocs.pm Thu Sep 1 19:20:05 2005
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.204 2005/08/31 06:36:41 raeburn Exp $
+# $Id: londocs.pm,v 1.205 2005/09/01 23:20:05 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -155,9 +155,7 @@
my ($ca,$cd)=split(/\@/,$env{'form.authorspace'});
$r->print('<h3>'.&mt('Copying Files').'</h3>');
my $title=$env{'form.authorfolder'};
- my ($ext)=($title=~s/\.(\w+)$//);
$title=&clean($title);
- $title.='.'.$ext;
my %replacehash=();
foreach (keys %env) {
if ($_=~/^form\.namefor\_(.+)/) {
@@ -168,7 +166,10 @@
$crs=~s/\_/\//g;
foreach (keys %replacehash) {
my $newfilename=$title.'/'.$replacehash{$_};
+ $newfilename=~s/\.(\w+)$//;
+ my $ext=$1;
$newfilename=&clean($newfilename);
+ $newfilename.='.'.$ext;
my @dirs=split(/\//,$newfilename);
my $path='/home/'.$ca.'/public_html';
my $makepath=$path;