source: main/trunk/greenstone3/web/interfaces/default/transform/layouts/main.xsl@ 35827

Last change on this file since 35827 was 35827, checked in by cstephen, 2 years ago

Fix erroneous change to empty <xsl:text> tags.

File size: 5.6 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" xmlns:java="http://xml.apache.org/xslt/java" xmlns:util="xalan://org.greenstone.gsdl3.util.XSLTUtil" xmlns:gslib="http://www.greenstone.org/skinning" xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" xmlns:lxslt="http://xml.apache.org/xslt" xmlns:result="http://www.example.com/results" xmlns:exsl="http://exslt.org/common" extension-element-prefixes="java util result exsl" exclude-result-prefixes="util java util gsf gslib">
3
4 <xsl:import href="header.xsl" />
5 <xsl:param name="lang" />
6 <xsl:include href="formatmanager.xsl" />
7
8 <!-- put the URL or path of your site here site -->
9 <!-- eg 'http://www.example.com/mysite' or '/mysite' -->
10 <xsl:template name="siteURL">
11 <xsl:value-of select="/page/pageResponse/metadataList/metadata[@name='siteURL']" />
12 </xsl:template>
13
14 <!-- the output format for this layout is html -->
15 <xsl:output method="html" omit-xml-declaration="yes" />
16
17 <xsl:template match="/">
18 <xsl:call-template name="mainTemplate" />
19 </xsl:template>
20
21 <!-- the main layout is defined here -->
22 <xsl:template name="mainTemplate">
23
24 <html lang="{$lang}">
25
26 <head>
27 <!-- ***** in header.xsl ***** -->
28 <xsl:call-template name="create-html-header" />
29 <xsl:call-template name="basketHeadTags" />
30 </head>
31
32 <body>
33 <xsl:call-template name="textDirectionAttribute" />
34 <xsl:call-template name="actionClass" />
35 <!-- Consider bringing this template call back, but wrapped up in an "if debug" ?? -->
36 <!--<xsl:call-template name="displayErrorsIfAny"/>-->
37 <a name="top">
38 <xsl:text> </xsl:text>
39 </a>
40
41 <div id="topArea" class="ui-state-default ui-corner-top">
42 <table>
43 <tbody>
44 <tr>
45 <td>
46 <div id="breadcrumbs">
47 <xsl:call-template name="breadcrumbs" />
48 <xsl:text> </xsl:text>
49 </div>
50 </td>
51
52 <!-- ***** in header.xsl ***** -->
53 <td>
54 <xsl:call-template name="home-help-preferences" />
55 </td>
56 </tr>
57 </tbody>
58 </table>
59 </div>
60
61 <div id="container" class="ui-corner-all">
62
63 <!-- ***** in header.xsl ***** -->
64 <xsl:call-template name="create-banner" />
65
66 <xsl:if test="/page/pageRequest/paramList/param[(@name='formatedit') and (@value='on')]">
67 <xsl:call-template name="formatmanagerpre" />
68 </xsl:if>
69
70 <!--
71 IMPORTANT: when copying this file to base your own custom interface's main.xsl on this one,
72 or when writing a main.xsl for your custom interface from scratch,
73 it is absolutely crucial to ensure the div element containing the xsl:apply-templates for /page
74 is given the id="gs_content".
75 Without this, many parts of GS3 will fail as they make use of gs_content whenever they make
76 calls to the GS server that include 'excerptid=gs_content' in the URL params.
77 For instance, connecting a client-GLI to a remote GS3 server and attempting to view
78 collections will fail as the user groups for a user will return null without this.
79 ADDITIONAL NOTE: it has not been investigated whether adding addition html elements inside the
80 div with id="gs_content" is wise. I've not checked whether such elements will be parsed out
81 properly and just the expected portions retrieved successfully by callers that requested
82 excerptid=gs_content.
83 -->
84 <div id="gs_content" class="ui-widget-content">
85 <!--
86 Show the content of the page.
87 to customise this part, edit the xsl file for the page you want to edit
88 -->
89 <xsl:apply-templates select="/page" />
90
91 </div>
92
93 <xsl:call-template name="gs_footer" />
94 </div>
95 </body>
96 </html>
97 </xsl:template>
98
99 <!-- default is to have nothing inthea rightSidebar -->
100 <xsl:template name="floatRightSidebar">
101 <div id="float-anchor" style="width: 30%; min-width:180px; float:right; margin: 0 0 10px 20px;">
102 <xsl:call-template name="rightSidebar" />
103 </div>
104 </xsl:template>
105
106 <!-- Default rule is to be empty => no rightSidebar to show -->
107 <!-- Gets overridden in pages such as query.xsl and classifier.xsl to display baskets and facet info elements -->
108 <xsl:template name="rightSidebar"></xsl:template>
109
110 <!-- Template controlling the footer. -->
111 <xsl:template name="gs_footer">
112 <div id="gs_footer" class="ui-widget-header ui-corner-bottom">
113 <a href="https://www.greenstone.org">
114 <gslib:poweredByGS3TextBar />
115 </a>
116 </div>
117 </xsl:template>
118
119</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.