--- loncom/publisher/lonpubdir.pm 2001/12/17 00:57:59 1.18 +++ loncom/publisher/lonpubdir.pm 2001/12/28 22:14:10 1.19 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # (Publication Handler # -# $Id: lonpubdir.pm,v 1.18 2001/12/17 00:57:59 harris41 Exp $ +# $Id: lonpubdir.pm,v 1.19 2001/12/28 22:14:10 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -37,6 +37,7 @@ # 03/24,03/29 Gerd Kortemeyer) # 03/31,04/03,05/09,06/23,08/18,08/20 Gerd Kortemeyer # 12/15 Scott Harrison +# 12/28 Gerd Kortemeyer # ### @@ -110,10 +111,12 @@ sub handler { my $docroot=$r->dir_config('lonDocRoot'); my $resdir=$docroot.'/res/'.$udom.'/'.$uname.$thisdisfn; + my $targetdir=$udom.'/'.$uname.$thisdisfn; my $linkdir='/~'.$uname.$thisdisfn; $r->print('
Filename | Modified | Status | ||
---|---|---|---|---|
Filename | Metadata | Modified | '. + 'Status | |
'.$disfilename. - ' | '.localtime($cmtime).' | '.localtime($cmtime). + ' | ' ); } } elsif (&Apache::loncommon::fileembstyle($extension) ne 'hdn') { my $status='Unpublished'; my $bgcol='#FFBBBB'; + my $title=' '; if (-e $resdir.'/'.$filename) { my ($rdev,$rino,$rmode,$rnlink, $ruid,$rgid,$rrdev,$rsize, @@ -151,9 +156,15 @@ sub handler { if ($rmtime>=$cmtime) { $status='Published'; $bgcol='#BBFFBB'; + $title= + ''. + &Apache::lonnet::metadata($targetdir.'/'.$filename,'title').''; } else { $status='Modified'; $bgcol='#FFFFBB'; + $title= + ''. + &Apache::lonnet::metadata($targetdir.'/'.$filename,'title').''; if (&Apache::loncommon::fileembstyle(($filename=~/\.(\w+)$/)) eq 'ssi') { $status.=' | '.localtime($cmtime).' | '.$status.' | '. + ''.$title. + ' | '.localtime($cmtime).' | '.$status.' | '. ''. 'Publish | ');