1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
2 | <xsl:stylesheet version="1.0"
|
---|
3 | xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
---|
4 | xmlns:java="http://xml.apache.org/xslt/java"
|
---|
5 | xmlns:util="xalan://org.greenstone.gsdl3.util.XSLTUtil"
|
---|
6 | extension-element-prefixes="java util"
|
---|
7 | exclude-result-prefixes="java util">
|
---|
8 |
|
---|
9 | <!-- style includes global params interface_name, page_lang, library_name -->
|
---|
10 | <xsl:include href="style.xsl"/>
|
---|
11 |
|
---|
12 | <xsl:output method="html"/>
|
---|
13 |
|
---|
14 | <xsl:template name="pageHead">
|
---|
15 | <head>
|
---|
16 | <title>
|
---|
17 | <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/>
|
---|
18 | </title>
|
---|
19 | </head>
|
---|
20 | </xsl:template>
|
---|
21 |
|
---|
22 | <xsl:template match="pageResponse">
|
---|
23 | <xsl:call-template name="greenstonePageBanner"/>
|
---|
24 | <center>
|
---|
25 | <xsl:apply-templates select="collectionList"/>
|
---|
26 | <xsl:apply-templates select="serviceClusterList"/>
|
---|
27 | <xsl:apply-templates select="serviceList"/>
|
---|
28 | </center>
|
---|
29 | </xsl:template>
|
---|
30 |
|
---|
31 |
|
---|
32 | <!-- the ancestor axis contains the parent of the context node, and its parent and so on. to pick one node among these: ancestor::elem-name. I dont know how this works if there are two nodes with the same name in the axis. -->
|
---|
33 | <xsl:template match="collectionList">
|
---|
34 | <xsl:for-each select="collection">
|
---|
35 | <p>
|
---|
36 | <a href="{$library_name}?a=p&sa=about&c={@name}">
|
---|
37 | <img width="150" border="1">
|
---|
38 | <xsl:attribute name="src">
|
---|
39 | <xsl:value-of select="metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="metadataList/metadata[@name='colIcon']"/>
|
---|
40 | </xsl:attribute>
|
---|
41 | <xsl:attribute name="alt">
|
---|
42 | <xsl:value-of select="metadataList/metadata[@name='colName']"/>
|
---|
43 | </xsl:attribute>
|
---|
44 | </img>
|
---|
45 | </a>
|
---|
46 | </p>
|
---|
47 | </xsl:for-each>
|
---|
48 | <xsl:call-template name="greenBar"/>
|
---|
49 | </xsl:template>
|
---|
50 |
|
---|
51 | <xsl:template match="serviceList">
|
---|
52 | <xsl:for-each select="service">
|
---|
53 | <p /> service name=<xsl:value-of select="@name"/>
|
---|
54 | </xsl:for-each>
|
---|
55 | </xsl:template>
|
---|
56 |
|
---|
57 | <xsl:template match="serviceClusterList">
|
---|
58 | <xsl:for-each select="serviceCluster">
|
---|
59 | <p/><a href="{$library_name}?a=p&sa=about&c={@name}"><xsl:value-of select='@name'/></a>
|
---|
60 | </xsl:for-each>
|
---|
61 | <xsl:call-template name="greenBar"/>
|
---|
62 | </xsl:template>
|
---|
63 |
|
---|
64 | </xsl:stylesheet>
|
---|
65 |
|
---|
66 |
|
---|