--- loncom/interface/portfolio.pm 2004/11/10 05:57:53 1.56 +++ loncom/interface/portfolio.pm 2004/11/22 22:59:32 1.57 @@ -33,8 +33,8 @@ use Apache::lonlocal; # receives a file name and path stub from username/userfiles/portfolio/ # returns an anchor tag consisting encoding filename and currentpath sub make_anchor { - my ($filename, $current_path) = @_; - my $anchor = ''.$filename.''; + my ($filename, $current_path, $current_mode, $field_name) = @_; + my $anchor = ''.$filename.''; return $anchor; } my $dirptr=16384; @@ -48,6 +48,7 @@ sub display_common { ''. ''. ''. + ''. ''. ''; $r->print($displayOut); @@ -57,17 +58,18 @@ sub display_common { ''. ''. ''. + ''. ''. ''; $r->print($displayOut); $r->print(''); my @tree = split (/\//,$current_path); - $r->print(''.&make_anchor('portfolio','/').'/'); + $r->print(''.&make_anchor('portfolio','/',$ENV{"form.mode"},$ENV{"form.fieldname"}).'/'); if (@tree > 1){ my $newCurrentPath = ''; for (my $i = 1; $i< @tree; $i++){ $newCurrentPath .= $tree[$i].'/'; - $r->print(&make_anchor($tree[$i],'/'.$newCurrentPath).'/'); + $r->print(&make_anchor($tree[$i],'/'.$newCurrentPath, $ENV{"form.mode"},$ENV{"form.fieldname"}).'/'); } } $r->print(''); @@ -121,7 +123,7 @@ sub display_directory { if ($dirptr&$testdir) { $r->print(''); $r->print('Go to ...'); - $r->print(''.&make_anchor($filename.'/',$current_path.$filename.'/').''); + $r->print(''.&make_anchor($filename.'/',$current_path.$filename.'/',$ENV{'form.mode'},$ENV{"form.fieldname"}).''); $r->print(''); } else { $r->print(''); @@ -186,7 +188,7 @@ sub display_file_select { if ($dirptr&$testdir) { $r->print(''); $r->print('Go to ...'); - $r->print(''.&make_anchor($filename.'/',$current_path.$filename.'/').''); + $r->print(''.&make_anchor($filename.'/',$current_path.$filename.'/',$ENV{'form.mode'},$ENV{"form.fieldname"}).''); $r->print(''); } else { $r->print(''); @@ -244,6 +246,7 @@ sub done { return ('

'.&mt('Done').'

'); }