source: trunk/gli/help/gen-many-html.xsl@ 11597

Last change on this file since 11597 was 11594, checked in by kjdon, 18 years ago

modified for the new XML format that works with the translator

  • Property svn:keywords set to Author Date Id Revision
File size: 2.3 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="Document">
7 <xsl:for-each select="Section">
8 <xsl:call-template name="processSection">
9 <xsl:with-param name="sectionHead" select="position()"/>
10 </xsl:call-template>
11 </xsl:for-each>
12 </xsl:template>
13
14
15 <xsl:template match="Reference">
16 <xsl:variable name="target" select="@target"/>
17 <a href="{@target}.htm"><xsl:value-of select="/Document//Section[@name=$target]/Title/Text"/></a>
18 </xsl:template>
19
20
21 <xsl:template match="Section"/>
22
23
24 <xsl:template match="Title"/>
25
26 <xsl:template match="Text">
27 <p><xsl:apply-templates/></p>
28 </xsl:template>
29
30 <xsl:template name="processSection">
31 <xsl:param name="sectionHead"/>
32
33 <html>
34 <head>
35 <title>The Greenstone Librarian Interface - Help Pages</title>
36 </head>
37 <body bgcolor="#E0F0E0">
38 <table border="2" bgcolor="#B0D0B0" cellpadding="5" cellspacing="0" width="100%">
39 <tr>
40 <td align="center" width="15%">
41 <img height="45" src="../gatherer_medium.gif" width="45"/>
42 </td>
43 <td align="center" width="*">
44 <a name="{@name}">
45 <xsl:call-template name="processTitle">
46 <xsl:with-param name="sectionNumber" select="$sectionHead"/>
47 <xsl:with-param name="sectionTitle" select="Title"/>
48 </xsl:call-template>
49 </a>
50 </td>
51 <td align="center" width="15%">
52 <img height="45" src="../gatherer_medium.gif" width="45"/>
53 </td>
54 </tr>
55 </table>
56
57 <xsl:apply-templates/>
58 </body>
59 </html>
60
61 <xsl:for-each select="Section">
62 <xsl:call-template name="processSection">
63 <xsl:with-param name="sectionHead" select="concat($sectionHead, '.', position())"/>
64 </xsl:call-template>
65 </xsl:for-each>
66 </xsl:template>
67
68
69 <xsl:template name="processTitle">
70 <xsl:param name="sectionNumber"/>
71 <xsl:param name="sectionTitle"/>
72
73 <font face="Verdana" size="5">
74 <strong>
75 <xsl:value-of select="concat($sectionNumber, ': ', $sectionTitle/Text)"/>
76 </strong>
77 </font>
78 </xsl:template>
79
80</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.