]> matita.cs.unibo.it Git - helm.git/commitdiff
Stylesheet whose input is an empty document. It calls the
authorClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Thu, 10 Jun 2004 14:06:38 +0000 (14:06 +0000)
committerClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Thu, 10 Jun 2004 14:06:38 +0000 (14:06 +0000)
new search engine (moowgle) passing the needed parameters.

helm/on-line/xslt/search.xsl [new file with mode: 0644]

diff --git a/helm/on-line/xslt/search.xsl b/helm/on-line/xslt/search.xsl
new file mode 100644 (file)
index 0000000..226b7d0
--- /dev/null
@@ -0,0 +1,80 @@
+<?xml version="1.0"?>
+
+<!-- Copyright (C) 2000, HELM Team                                     -->
+<!--                                                                   -->
+<!-- This file is part of HELM, an Hypertextual, Electronic            -->
+<!-- Library of Mathematics, developed at the Computer Science         -->
+<!-- Department, University of Bologna, Italy.                         -->
+<!--                                                                   -->
+<!-- HELM is free software; you can redistribute it and/or             -->
+<!-- modify it under the terms of the GNU General Public License       -->
+<!-- as published by the Free Software Foundation; either version 2    -->
+<!-- of the License, or (at your option) any later version.            -->
+<!--                                                                   -->
+<!-- HELM is distributed in the hope that it will be useful,           -->
+<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of    -->
+<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the     -->
+<!-- GNU General Public License for more details.                      -->
+<!--                                                                   -->
+<!-- You should have received a copy of the GNU General Public License -->
+<!-- along with HELM; if not, write to the Free Software               -->
+<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston,            -->
+<!-- MA  02111-1307, USA.                                              -->
+<!--                                                                   -->
+<!-- For details, see the HELM World-Wide-Web page,                    -->
+<!-- http://cs.unibo.it/helm/.                                         -->
+
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+                              xmlns:m="http://www.w3.org/1998/Math/MathML"
+                              xmlns:helm="http://www.cs.unibo.it/helm"
+                              xmlns:xlink="http://www.w3.org/1999/xlink">
+
+<!--***********************************************************************--> 
+<!-- From MathML presentation or HTML to themselves with links             -->
+<!-- HELM Group: Asperti, Padovani, Sacerdoti, Schena                      -->
+<!-- First draft: March 16 2001, Andrea Asperti                            -->
+<!--***********************************************************************--> 
+
+<xsl:param name="action" select="''"/>
+<xsl:param name="expression" select="''"/>
+<xsl:param name="choices" select="''"/>
+<xsl:param name="interp" select="''"/>
+<xsl:param name="constraints" select="''"/>
+<xsl:param name="searchengineURL" select="''"/>
+
+<xsl:include href="links_library.xsl"/>
+
+<xsl:variable name="quoted_expression">
+ <xsl:call-template name="quote">
+  <xsl:with-param name="s" select="$expression"/>
+ </xsl:call-template>
+</xsl:variable>
+
+<xsl:variable name="quoted_choices">
+ <xsl:call-template name="quote">
+  <xsl:with-param name="s" select="$choices"/>
+ </xsl:call-template>
+</xsl:variable>
+
+<xsl:variable name="quoted_constraints">
+ <xsl:call-template name="quote">
+  <xsl:with-param name="s" select="$constraints"/>
+ </xsl:call-template>
+</xsl:variable>
+
+<xsl:variable name="param_constraints">
+ <xsl:choose>
+  <xsl:when test="$constraints=''">
+   <xsl:value-of select="''"/>
+  </xsl:when>
+  <xsl:otherwise>
+   <xsl:value-of select="concat('&amp;constraints=',$quoted_constraints)"/>
+  </xsl:otherwise>
+ </xsl:choose>
+</xsl:variable>
+
+<xsl:template match="/">
+ <xsl:copy-of select="document(concat($searchengineURL,$action,'?expression=',$quoted_expression,'&amp;choices=',$quoted_choices,'&amp;interpretation_choices=',$interp,$param_constraints))"/> 
+</xsl:template>
+
+</xsl:stylesheet>