root/documentation/trunk/tutorials/processing/xml-to-wiki-index.xsl @ 33036

Revision 33036, 2.2 KB (checked in by ak19, 17 months ago)

Bringing the xsl that generates wiki-index.txt up to date with the changeover to dokuwiki.

  • Property svn:keywords set to Author Date Id Revision
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<xsl:stylesheet version="1.0"
3  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
4
5  <xsl:param name="gs-major-version"/>
6  <xsl:include href="common.xsl"/>
7
8  <xsl:output method="text"/>
9
10  <xsl:variable name="currentfolder">gs<xsl:value-of select="$gs-major-version"/>-current</xsl:variable>
11  <xsl:variable name="es">Spanish</xsl:variable>
12  <xsl:variable name="fr">French</xsl:variable>
13  <xsl:variable name="ru">Russian</xsl:variable>
14  <!--
15      <xsl:variable name="sampledir">{{SERVER}}{{SCRIPTPATH}}/gsdoc/tutorial/<xsl:value-of select="$currentfolder"/>/sample_files</xsl:variable>
16      <xsl:variable name="htmldir">{{SERVER}}{{SCRIPTPATH}}/gsdoc/tutorial/<xsl:value-of select="$currentfolder"/></xsl:variable>
17  -->
18  <xsl:variable name="server-scriptpath">http://wiki.greenstone.org/</xsl:variable>
19  <xsl:variable name="sampledir"><xsl:value-of select="$server-scriptpath"/>/gsdoc/tutorial/<xsl:value-of select="$currentfolder"/>/sample_files</xsl:variable>
20  <xsl:variable name="htmldir"><xsl:value-of select="$server-scriptpath"/>/gsdoc/tutorial/<xsl:value-of select="$currentfolder"/></xsl:variable>
21  <xsl:template match="TutorialList">
22'''<xsl:apply-templates select="Title/Text"/>'''<xsl:text>
23</xsl:text>
24These work with Greenstone <xsl:value-of select="Version/@current"/>. [<xsl:value-of select="$htmldir"/>/en/all_tutorials.html <xsl:apply-templates select="/TutorialList/SupplementaryText/Text[@id='print']"/>]<xsl:text>
25</xsl:text>
26Translations of March 2006 version (for Greenstone 2.70):
27[<xsl:value-of select="$htmldir"/>/es/index.html <xsl:value-of select="$es"/>]
28[<xsl:value-of select="$htmldir"/>/fr/index.html <xsl:value-of select="$fr"/>]
29[<xsl:value-of select="$htmldir"/>/ru/index.html <xsl:value-of select="$ru"/>]<xsl:text>
30</xsl:text>
31    <xsl:apply-templates select="Tutorial"/>
32  </xsl:template>
33
34  <xsl:template match="Tutorial"><xsl:text>
35
36</xsl:text>
37**[[<xsl:value-of select="$htmldir"/>/en/<xsl:value-of select="@id"/>.htm|<xsl:apply-templates select="Title/Text"/>]]**
38<xsl:for-each select="Content//Synopsis">
39''<xsl:apply-templates/>''</xsl:for-each>
40    <xsl:for-each select="Content/Heading/Text">
41  * <xsl:apply-templates/>
42    </xsl:for-each>
43  </xsl:template>
44
45</xsl:stylesheet>
Note: See TracBrowser for help on using the browser.