--- loncom/publisher/loncfile.pm 2007/04/26 21:17:16 1.83
+++ loncom/publisher/loncfile.pm 2007/07/10 23:34:54 1.84
@@ -9,7 +9,7 @@
# and displays a page showing the results of the action.
#
#
-# $Id: loncfile.pm,v 1.83 2007/04/26 21:17:16 albertel Exp $
+# $Id: loncfile.pm,v 1.84 2007/07/10 23:34:54 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -340,6 +340,12 @@ sub cleanDest {
$dest=~s|.*/||;
}
}
+ if ($dest =~ /\.(\d+)\.(\w+)$/){
+ $request->print(''
+ .&mt('Bad filename [_1].
(name).(number).(extension) not allowed.
Removing the .number. from requested filename.',$dest)
+ .'');
+ $dest =~ s/\.(\d+)(\.\w+)$/$2/;
+ }
if ($foundbad) {
$request->print("
".&mt('Invalid characters in requested name have been removed.')."
"); }