source: tags/gsdl-2_70u-distribution/gli/help/gen-one-html.xsl@ 11745

Last change on this file since 11745 was 11092, checked in by kjdon, 18 years ago

removed references to Anchor, Contents, ObviousSentence, which are no longer used

  • Property svn:keywords set to Author Date Id Revision
File size: 1.9 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3
4 <xsl:output method="html" encoding="UTF-8"/>
5
6 <xsl:template match="Break">
7 <p/>
8 </xsl:template>
9
10 <xsl:template match="Document">
11 <html>
12 <head>
13 <title>The Greenstone Librarian Interface - Help Pages</title>
14 </head>
15 <body bgcolor="#E0F0E0">
16 <xsl:for-each select="Section">
17 <xsl:call-template name="processSection">
18 <xsl:with-param name="sectionHead" select="position()"/>
19 </xsl:call-template>
20 </xsl:for-each>
21 </body>
22 </html>
23 </xsl:template>
24
25 <xsl:template match="Reference">
26 <a href="#{@target}"><xsl:apply-templates/></a>
27 </xsl:template>
28
29 <xsl:template match="Section"/>
30
31 <xsl:template match="Title"/>
32
33
34 <xsl:template name="processSection">
35 <xsl:param name="sectionHead"/>
36
37 <xsl:if test="Title">
38 <a name="{@name}">
39 <xsl:call-template name="processTitle">
40 <xsl:with-param name="sectionNumber" select="$sectionHead"/>
41 <xsl:with-param name="sectionTitle" select="Title"/>
42 </xsl:call-template>
43 </a>
44 </xsl:if>
45
46 <xsl:apply-templates/>
47
48 <xsl:for-each select="Section">
49 <xsl:call-template name="processSection">
50 <xsl:with-param name="sectionHead" select="concat($sectionHead, '.', position())"/>
51 </xsl:call-template>
52 </xsl:for-each>
53 </xsl:template>
54
55
56 <xsl:template name="processTitle">
57 <xsl:param name="sectionNumber"/>
58 <xsl:param name="sectionTitle"/>
59
60 <xsl:choose>
61 <xsl:when test="contains($sectionNumber, '.')">
62 <h3>Section <xsl:value-of select="concat($sectionNumber, ': ', $sectionTitle)"/></h3>
63 </xsl:when>
64 <xsl:otherwise>
65 <h1>Section <xsl:value-of select="concat($sectionNumber, ': ', $sectionTitle)"/></h1>
66 </xsl:otherwise>
67 </xsl:choose>
68 </xsl:template>
69
70</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.