source: main/trunk/greenstone3/web/interfaces/default/transform/gli4gs3.xsl@ 32155

Last change on this file since 32155 was 32155, checked in by ak19, 6 years ago

Shouldn't hardcode localhost for codebase. Still not sure why, after this change, downloading the jnlp file on a remote machine results in an error due it searching for the jnlp resource on locahost.

File size: 2.9 KB
RevLine 
[32127]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
[32150]9 <xsl:output method="xml"/>
[32127]10
[32150]11 <!--
12 1. This XSLT rewrites the applet page generated by PageAction, from the top node of / down,
13 to replace it with a JNLP Java Web Start file to launch GLI (web/applet/SignedGatherer.java).
14 2. Putting in an xml processing instruction doesn't seem to go through and causes stylesheet transform errors
15 after following https://www.w3schools.com/xml/ref_xsl_el_processing-instruction.asp
16 -->
17 <xsl:template match="/">
18 <!--
19 /*
20 * Java Web Start support for Greenstone Librarian Interface (GLI) applet.
21 * Copyright (C) 2002 New Zealand Digital Library, http://www.nzdl.org
22 *
23 * This program is free software; you can redistribute it and/or modify
24 * it under the terms of the GNU General Public License as published by
25 * the Free Software Foundation; either version 2 of the License, or
26 * (at your option) any later version.
27 *
28 * This program is distributed in the hope that it will be useful,
29 * but WITHOUT ANY WARRANTY; without even the implied warranty of
30 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
31 * GNU General Public License for more details.
32 *
33 * You should have received a copy of the GNU General Public License
34 * along with this program; if not, write to the Free Software
35 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
36 */
37 -->
38 <jnlp
[32155]39 spec="1.0+"
40 href="GLIappWebStart.jnlp"><!--codebase="http://localhost:8383/greenstone3/applet"-->
41 <xsl:attribute name="codebase"><xsl:value-of select='/page/pageRequest/@baseURL'/>applet</xsl:attribute>
[32150]42 <information>
43 <title>Greenstone Librarian Interface</title>
44 <vendor>New Zealand Digital Library</vendor>
45 <homepage href="http://www.greenstone.org/"/>
46 <description>GLI</description>
47 <description kind="short">Greenstone Librarian Interface (GLI) as Web Start Application over JNLP</description>
48 <offline-allowed/>
49 </information>
50 <resources>
51 <j2se version="1.7+"/>
52 <jar href="SignedGatherer.jar"/>
53 </resources>
54 <application-desc main-class="org.greenstone.gatherer.WebGatherer">
55 <!--<argument>-gwcgi=/greenstone3</argument>
56 <argument>-gsdl3=true</argument>-->
57 <argument>-gwcgi=<xsl:value-of select="/page/pageResponse/Applet/PARAM[@name='gwcgi']/@value" /></argument>
58 <argument>-gsdl3=<xsl:value-of select="/page/pageResponse/Applet/PARAM[@name='gsdl3']/@value" /></argument>
59 </application-desc>
60 <!-- https://stackoverflow.com/questions/12600076/getting-user-home-folder-from-jws-signed-jar -->
61 <security>
62 <all-permissions/>
63 </security>
64 </jnlp>
65
[32127]66 </xsl:template>
67
[32150]68</xsl:stylesheet>
[32127]69
Note: See TracBrowser for help on using the repository browser.