version 1.73, 2005/02/11 00:18:14
|
version 1.75, 2005/02/17 08:29:43
|
Line 499 sub createdir {
|
Line 499 sub createdir {
|
sub handler { |
sub handler { |
# this handles file management |
# this handles file management |
my $r = shift; |
my $r = shift; |
my $bodytag; |
|
my $portfolio_root = &Apache::loncommon::propath($ENV{'user.domain'}, |
my $portfolio_root = &Apache::loncommon::propath($ENV{'user.domain'}, |
$ENV{'user.name'}). |
$ENV{'user.name'}). |
'/userfiles/portfolio'; |
'/userfiles/portfolio'; |
&Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'}, |
&Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'}, |
['selectfile','currentpath','meta', |
['selectfile','currentpath','meta', |
'currentfile','action','fieldname','mode','rename']); |
'currentfile','action','fieldname','mode','rename']); |
if ($ENV{"form.mode"} eq 'selectfile'){ |
|
$bodytag = &Apache::loncommon::bodytag('Portfolio Manager',undef,undef,1); |
|
} else { |
|
$bodytag = &Apache::loncommon::bodytag('Portfolio Manager'); |
|
} |
|
|
|
&Apache::loncommon::no_cache($r); |
&Apache::loncommon::no_cache($r); |
&Apache::loncommon::content_type($r,'text/html'); |
&Apache::loncommon::content_type($r,'text/html'); |
$r->send_http_header; |
$r->send_http_header; |
# Give the LON-CAPA page header |
# Give the LON-CAPA page header |
$r->print('<html><head><title>'. |
my $html=&Apache::lonxml::xmlbegin(); |
|
$r->print($html.'<head><title>'. |
&mt('Portfolio Manager'). |
&mt('Portfolio Manager'). |
"</title></head>\n". |
"</title></head>\n"); |
$bodytag); |
if ($ENV{"form.mode"} eq 'selectfile'){ |
|
$r->print(&Apache::loncommon::bodytag('Portfolio Manager',undef,undef,1)); |
|
} else { |
|
$r->print(&Apache::loncommon::bodytag('Portfolio Manager')); |
|
} |
$r->rflush(); |
$r->rflush(); |
if (($ENV{'form.storeupl'} eq 'Upload') & (!$ENV{'form.uploaddoc.filename'})){ |
if (($ENV{'form.storeupl'} eq 'Upload') & (!$ENV{'form.uploaddoc.filename'})){ |
$r->print('<font color="red"> No file was selected to upload.'. |
$r->print('<font color="red"> No file was selected to upload.'. |