Improve OAI Server MARC21 and UNIMARC XSL
authorFrédéric Demians <f.demians@tamil.fr>
Fri, 18 Sep 2009 09:07:35 +0000 (11:07 +0200)
committerGalen Charlton <gmcharlt@gmail.com>
Fri, 30 Apr 2010 03:09:04 +0000 (23:09 -0400)
Dublin Core schema name space was repeated for each field
as attribute rather than at <oai_dc:dc> level. This reduces
significantly the size of OAI server responses.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2OAIDC.xsl
koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2OAIDC.xsl

index 9a3ecb1..60975e0 100644 (file)
                        </oai_dc:dcCollection>
                </xsl:if>
                <xsl:if test="marc:record">
-                       <oai_dc:dc xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
+          <oai_dc:dc
+            xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
+            xmlns:dc="http://purl.org/dc/elements/1.1/"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+            xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
                                <xsl:apply-templates/>
                        </oai_dc:dc>
                </xsl:if>
index a1f2bcf..27c78ed 100644 (file)
                        </oai_dc:dcCollection>
                </xsl:if>
                <xsl:if test="marc:record">
-                       <oai_dc:dc xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
+          <oai_dc:dc
+            xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
+            xmlns:dc="http://purl.org/dc/elements/1.1/"
+            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+            xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
                                <xsl:apply-templates/>
                        </oai_dc:dc>
                </xsl:if>