[Koha-devel] Default XML entity encoding in C4::Record::marc2marcxml
Bernardo Gonzalez Kriegel
bgkriegel at gmail.com
Sat Feb 9 14:05:26 CET 2013
Hi,
if you try to export a record from opac or intranet to marcxml, the
record has accents or other symbols replaced by character entities.
The function C4::record::marc2marcxml expects 4 arguments, the last
one instructs to do or not that kind of replacement.
sub marc2marcxml {
my ($marc,$encoding,$flavour,$dont_entity_encode) = @_;
...
# entity encode the XML unless instructed not to
unless ($dont_entity_encode) {
my ($marcxml_entity_encoded) = _entity_encode($marcxml);
$marcxml = $marcxml_entity_encoded;
}
But for example in opac-export.pl is called simply as
elsif ($format =~ /marcxml/) {
$marc = marc2marcxml($marc);
$format = 'marcxml';
}
Is there a reason to do the character entity encoding by default?
Regards,
Bernardo
--
Bernardo Gonzalez Kriegel
bgkriegel at gmail.com
More information about the Koha-devel
mailing list