version 1.164, 2004/02/27 17:27:51
|
version 1.166, 2004/04/14 18:29:32
|
Line 126 use Apache::loncommon();
|
Line 126 use Apache::loncommon();
|
use Apache::lonmysql; |
use Apache::lonmysql; |
use Apache::lonlocal; |
use Apache::lonlocal; |
use Apache::loncfile; |
use Apache::loncfile; |
use Apache::lonmeta; |
use LONCAPA::lonmetadata; |
use Apache::lonmsg; |
use Apache::lonmsg; |
use vars qw(%metadatafields %metadatakeys); |
use vars qw(%metadatafields %metadatakeys); |
|
|
Line 809 sub store_metadata {
|
Line 809 sub store_metadata {
|
$metadata{'url'}."'"); |
$metadata{'url'}."'"); |
if ($#oldmeta==0) { |
if ($#oldmeta==0) { |
# yes, there is one old entry, transfer to newmetadata |
# yes, there is one old entry, transfer to newmetadata |
%newmetadata=&Apache::lonmeta::metadata_col_to_hash(@{$oldmeta[0]}); |
%newmetadata=&LONCAPA::lonmetadata::metadata_col_to_hash(@{$oldmeta[0]}); |
# remove old entry |
# remove old entry |
$status=&Apache::lonmysql::remove_from_table |
$status=&Apache::lonmysql::remove_from_table |
('metadata','url',$metadata{'url'}); |
('metadata','url',$metadata{'url'}); |
Line 945 sub publish {
|
Line 945 sub publish {
|
} |
} |
$outstring=~s/\n*(\<\/[^\>]+\>)\s*$/$allowstr\n$1\n/s; |
$outstring=~s/\n*(\<\/[^\>]+\>)\s*$/$allowstr\n$1\n/s; |
|
|
### FIXME: is this really what we want? |
|
# I dont' think so, to will corrupt any UTF-8 resources at least, |
|
# and any encoding other than ISO-8859-1 will probably break |
|
#Encode any High ASCII characters |
|
#$outstring=&HTML::Entities::encode($outstring,"\200-\377"); |
|
# ------------------------------------------------------------- Write modified. |
# ------------------------------------------------------------- Write modified. |
|
|
{ |
{ |
Line 1419 sub phasetwo {
|
Line 1414 sub phasetwo {
|
print $mfh ' '.$_.'="'.$value.'"'; |
print $mfh ' '.$_.'="'.$value.'"'; |
} |
} |
print $mfh '>'. |
print $mfh '>'. |
&HTML::Entities::encode($metadatafields{$unikey}) |
&HTML::Entities::encode($metadatafields{$unikey},'<>&"') |
.'</'.$tag.'>'; |
.'</'.$tag.'>'; |
} |
} |
} |
} |