version 1.1092, 2010/11/01 21:19:50
|
version 1.1093, 2010/11/10 14:44:19
|
Line 2352 sub resizeImage {
|
Line 2352 sub resizeImage {
|
|
|
# --------------- Take an uploaded file and put it into the userfiles directory |
# --------------- Take an uploaded file and put it into the userfiles directory |
# input: $formname - the contents of the file are in $env{"form.$formname"} |
# input: $formname - the contents of the file are in $env{"form.$formname"} |
# the desired filenam is in $env{"form.$formname.filename"} |
# the desired filename is in $env{"form.$formname.filename"} |
# $context - possible values: coursedoc, existingfile, overwrite, |
# $context - possible values: coursedoc, existingfile, overwrite, |
# canceloverwrite, or ''. |
# canceloverwrite, or ''. |
# if 'coursedoc': upload to the current course |
# if 'coursedoc': upload to the current course |
Line 2442 sub userfileupload {
|
Line 2442 sub userfileupload {
|
} |
} |
if ($subdir eq 'scantron') { |
if ($subdir eq 'scantron') { |
$fname = 'scantron_orig_'.$fname; |
$fname = 'scantron_orig_'.$fname; |
} else { |
} else { |
$fname="$subdir/$fname"; |
$fname="$subdir/$fname"; |
} |
} |
if ($context eq 'coursedoc') { |
if ($context eq 'coursedoc') { |
Line 7288 sub is_locked {
|
Line 7288 sub is_locked {
|
my ($file_name, $domain, $user) = @_; |
my ($file_name, $domain, $user) = @_; |
my @check; |
my @check; |
my $is_locked; |
my $is_locked; |
push @check, $file_name; |
push (@check,$file_name); |
my %locked = &get('file_permissions',\@check, |
my %locked = &get('file_permissions',\@check, |
$env{'user.domain'},$env{'user.name'}); |
$env{'user.domain'},$env{'user.name'}); |
my ($tmp)=keys(%locked); |
my ($tmp)=keys(%locked); |
Line 7305 sub is_locked {
|
Line 7305 sub is_locked {
|
} else { |
} else { |
$is_locked = 'false'; |
$is_locked = 'false'; |
} |
} |
|
return $is_locked; |
} |
} |
|
|
sub declutter_portfile { |
sub declutter_portfile { |