followup : auto_truncation 3287252c0
[koha.git] / C4 / Record.pm
index 63bba6d..2be4751 100644 (file)
@@ -248,7 +248,7 @@ sub marc2dcxml {
                $crosswalk = MARC::Crosswalk::DublinCore->new( qualified => 1 );
        }
        my $dcxml = $crosswalk->as_dublincore($marc_record_obj);
-       my $dcxmlfinal = "<?xml version=\"1.0\"?>\n";
+       my $dcxmlfinal = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n";
        $dcxmlfinal .= "<metadata
   xmlns=\"http://example.org/myapp/\"
   xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
@@ -278,7 +278,7 @@ sub marc2modsxml {
        my ($marc) = @_;
        # grab the XML, run it through our stylesheet, push it out to the browser
        my $xmlrecord = marc2marcxml($marc);
-       my $xslfile = C4::Context->config('intranetdir')."/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2MODS3-1.xsl";
+       my $xslfile = C4::Context->config('intrahtdocs')."/prog/en/xslt/MARC21slim2MODS3-1.xsl";
        my $parser = XML::LibXML->new();
        my $xslt = XML::LibXSLT->new();
        my $source = $parser->parse_string($xmlrecord);
@@ -381,7 +381,7 @@ sub html2marcxml {
                                                $marcxml.="<leader>@$values[$i]</leader>\n";
                                                $first=1;
                                        # rest of the fixed fields
-                                       } elsif (@$tags[$i] < 010) { #FIXME: <10 was the way it was, there might even be a better way
+                                       } elsif (@$tags[$i] lt '010') { # don't compare numerically 010 == 8
                                                $marcxml.="<controlfield tag=\"@$tags[$i]\">@$values[$i]</controlfield>\n";
                                                $first=1;
                                        } else {