Added new fundamental filter 'xslt'. This filter reads XML records
[idzebra-moved-to-github.git] / test / xslt / marc1.xsl
1 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
2  xmlns:m="http://www.loc.gov/MARC21/slim"
3  xmlns:z="http://indexdata.dk/zebra/indexing/1"
4  version="1.0">
5
6 <xsl:output indent="yes"
7       method="xml"
8       version="1.0"
9       encoding="UTF-8"/>
10
11      <xsl:template match="/m:record/m:controlfield[@tag=001]">
12        <z:index field="control">
13          <xsl:apply-templates match="."/>
14        </z:index>
15      </xsl:template>
16  
17      <xsl:template match="/m:record/m:datafield[@tag=245]">
18        <z:index field="title">
19          <xsl:apply-templates match="."/>
20        </z:index>
21      </xsl:template>
22  
23 </xsl:stylesheet>