Diff for /loncom/interface/lonmeta.pm between versions 1.4 and 1.6

version 1.4, 2000/11/27 23:10:59 version 1.6, 2001/08/10 17:16:06
Line 35  sub handler { Line 35  sub handler {
       $content{$_}=&Apache::lonnet::metadata($uri,$_);        $content{$_}=&Apache::lonnet::metadata($uri,$_);
   } split(/\,/,&Apache::lonnet::metadata($uri,'keys'));    } split(/\,/,&Apache::lonnet::metadata($uri,'keys'));
   
   # ------------------------------------------------------------------ Hide stuff
     if (!$ENV{'user.adv'}) {
       map {
         $content{$_}='<i>- not displayed -</i>';
       } ('keywords','notes','abstract','subject');
     }
   
 # --------------------------------------------------------------- Render Output  # --------------------------------------------------------------- Render Output
   
 my $creationdate=localtime($content{'creationdate'});  my $creationdate=localtime($content{'creationdate'});
Line 75  ENDHEAD Line 82  ENDHEAD
   map {    map {
       my $name=$_;        my $name=$_;
       my $display=&Apache::lonnet::metadata($uri,$name.'.display');        my $display=&Apache::lonnet::metadata($uri,$name.'.display');
       unless ($display) { $display=$name; };         unless ($display) { $display=$name; };
       $r->print('<b>'.$display.':</b> '.$content{$name}.'<br>');        my $otherinfo='';
         map {
             if (defined(&Apache::lonnet::metadata($uri,$name.'.'.$_))) {
                $otherinfo.=' '.$_.'='.
    &Apache::lonnet::metadata($uri,$name.'.'.$_).'; ';
             }
         } ('name','part','type','default'); 
         $r->print('<b>'.$display.':</b> '.$content{$name});
         if ($otherinfo) {
            $r->print(' ('.$otherinfo.')');
         }
         $r->print("<br>\n");
   } sort keys %content;    } sort keys %content;
   $r->print('</body></html>');    $r->print('</body></html>');
   return OK;    return OK;

Removed from v.1.4  
changed lines
  Added in v.1.6


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>