root/main/trunk/greenstone3/web/interfaces/default/transform/pages/rss.xsl @ 30778

Revision 30778, 1.3 KB (checked in by kjdon, 3 years ago)

removing hard coded text fragments from xsl/js files

Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" exclude-result-prefixes="xsl">
3        <!-- exclude-result-prefixes="#default">-->
4
5  <!-- Adding the xml processing instruction, see http://www.xml.com/lpt/a/1027 -->
6  <xsl:output method="xml" version="1.0" encoding="utf-8"/>
7 
8
9  <!-- select only the rss child of /page/pageResponse and then copy all its attributes and
10       descendant elements and their attributes too into the output
11       http://stackoverflow.com/questions/1141216/xsl-copy-the-entire-xml-except-a-parent-node-but-keep-its-child-node
12       http://stackoverflow.com/questions/5378610/copy-xml-document-with-all-elements-except-a-black-list-of-elements
13       http://stackoverflow.com/questions/5876382/using-xslt-to-copy-all-nodes-in-xml
14
15       To do a straightforward copy of input into output:
16       <xsl:template match="/">
17     <xsl:copy-of select="." />
18       </xsl:template>
19    -->
20
21 <xsl:template match="/page">
22    <xsl:apply-templates select="pageResponse/rss"/>
23  </xsl:template>
24
25  <!--Identity template, copies all content of matching template(s) into the output -->
26  <xsl:template match="@* | node()">
27    <xsl:copy>
28      <xsl:apply-templates select="@* | node()"/>
29    </xsl:copy>
30  </xsl:template>
31
32</xsl:stylesheet> 
33
Note: See TracBrowser for help on using the browser.