version 1.25, 2003/02/18 21:17:00
|
version 1.28, 2003/03/14 19:29:36
|
Line 101 sub dynamicmeta {
|
Line 101 sub dynamicmeta {
|
# ------------------------------------- Try to make an alt tag if there is none |
# ------------------------------------- Try to make an alt tag if there is none |
|
|
sub alttag { |
sub alttag { |
my $src=shift; |
my ($base,$src)=@_; |
return 'None'; |
my $fullpath=&Apache::lonnet::hreflocation($base,$src); |
|
my $alttag=&Apache::lonnet::metadata($fullpath,'title').' '. |
|
&Apache::lonnet::metadata($fullpath,'subject').' '. |
|
&Apache::lonnet::metadata($fullpath,'abstract'); |
|
$alttag=~s/\s+/ /gs; |
|
$alttag=~s/\"//gs; |
|
$alttag=~s/\'//gs; |
|
$alttag=~s/\s+$//gs; |
|
$alttag=~s/^\s+//gs; |
|
if ($alttag) { return $alttag; } else |
|
{ return 'No information available'; } |
} |
} |
|
|
# -------------------------------------------------------------- Pretty display |
# -------------------------------------------------------------- Pretty display |
Line 310 $dynmeta{$_}." </td></tr>\n");
|
Line 320 $dynmeta{$_}." </td></tr>\n");
|
'<h4>Error Messages (visible to author and co-authors only)</h4>'); |
'<h4>Error Messages (visible to author and co-authors only)</h4>'); |
my %errormsgs=&Apache::lonnet::dump('nohist_res_msgs',$1,$2); |
my %errormsgs=&Apache::lonnet::dump('nohist_res_msgs',$1,$2); |
foreach (keys %errormsgs) { |
foreach (keys %errormsgs) { |
if ($_=~/^$disuri\_\d+$/) { |
if ($_=~/^\Q$disuri\E\_\d+$/) { |
my %content=&Apache::lonmsg::unpackagemsg($errormsgs{$_}); |
my %content=&Apache::lonmsg::unpackagemsg($errormsgs{$_}); |
$r->print('<b>'.$content{'time'}.'</b>: '.$content{'message'}. |
$r->print('<b>'.$content{'time'}.'</b>: '.$content{'message'}. |
'<br />'); |
'<br />'); |
Line 370 $bodytag
|
Line 380 $bodytag
|
<form method="post"> |
<form method="post"> |
ENDEDIT |
ENDEDIT |
foreach ('author','title','subject','keywords','abstract','notes', |
foreach ('author','title','subject','keywords','abstract','notes', |
'copyright','language') { |
'copyright','customdistributionfile','language') { |
if ($ENV{'form.new_'.$_}) { |
if ($ENV{'form.new_'.$_}) { |
$Apache::lonpublisher::metadatafields{$_}=$ENV{'form.new_'.$_}; |
$Apache::lonpublisher::metadatafields{$_}=$ENV{'form.new_'.$_}; |
} |
} |